Walter Dörwald
30537a46ac
Add a few test cases to increase code coverage:
...
From:
69.73% of 294 source lines executed in file ./Modules/_codecsmodule.c
79.47% of 487 source lines executed in file Python/codecs.c
78.45% of 3643 source lines executed in file Objects/unicodeobject.c
To:
70.41% of 294 source lines executed in file ./Modules/_codecsmodule.c
82.75% of 487 source lines executed in file Python/codecs.c
80.76% of 3638 source lines executed in file Objects/unicodeobject.c
This actually unearthed a bug in the handling of None
values in PyUnicode_EncodeCharmap.
2003-01-08 23:22:13 +00:00
Walter Dörwald
395bb49555
Add a test that exercises the error handling part of
...
PyUnicode_EncodeDecimal().
2003-01-08 23:02:34 +00:00
Walter Dörwald
adc727490b
Fix charmapencode_lookup(), so that a None value in the mapping
...
is treated as "character maps to <undefined>" and not as
"character mapping must return integer, None or str".
2003-01-08 22:01:33 +00:00
Tim Peters
6757c1e856
SF patch 661583: Remove old code from lib\os.py
...
A patch from Andrew Wilkinson to change some bizarre old exec statements
specific to NT and CE.
2003-01-08 21:20:57 +00:00
Tim Peters
7d4b315cca
Deleted pickle/unpickle code for the old datetime and time classes -- it's
...
unreachable now.
2003-01-08 20:51:36 +00:00
Tim Peters
0bf60bd67f
Utterly minimal changes to collapse datetimetz into datetime, and timetz
...
into time. This is little more than *exporting* the datetimetz object
under the name "datetime", and similarly for timetz. A good implementation
of this change requires more work, but this is fully functional if you
don't stare too hard at the internals (e.g., right now a type named
"datetime" shows up as a base class of the type named "datetime"). The
docs also need extensive revision, not part of this checkin.
2003-01-08 20:40:01 +00:00
Walter Dörwald
034d97605d
Remove variable owned from PyUnicode_FromEncodedObject, which is unused
...
(except for Py_DECREF calls) since the introduction of __unicode__.
2003-01-08 20:38:39 +00:00
Steve Holden
8a978f7cde
Fix bug 427345 [related to IE's additional input on POST request].
2003-01-08 18:53:18 +00:00
Jack Jansen
472e7db5c0
Various tweaks to make the test work on the Mac.
2003-01-08 16:37:03 +00:00
Jack Jansen
b11ce9b96c
Always define getenv(), as suggested by Guido. This means that os.getenv() is also defined for MacPython-OS9 (even though it doesn't actually do anything useful), and it shouldn't hurt on other platforms.
2003-01-08 16:33:40 +00:00
Jack Jansen
52941a8348
Test that chmod() actually exists before calling it (it doesn't on MacOS9).
2003-01-08 16:33:16 +00:00
Jack Jansen
27d19c40bc
Removed the SetDates warning. The warning is in the readme, and the print statement was too obtrusive (it appeared during the installation process, and the user needed to close the resulting window manually).
2003-01-08 16:32:29 +00:00
Jack Jansen
746096576b
quashed another case of the 32-bit warning.
2003-01-08 16:32:09 +00:00
Jack Jansen
6797514557
Updated the list of expected skips for MacPython-OS9.
2003-01-08 16:31:11 +00:00
Jack Jansen
2918ae8fe6
n the Mac the frozen import that should fail actually succeeds, and we know it, so skip the test in stead of confusing the end user.
2003-01-08 16:30:54 +00:00
Jack Jansen
ce92147cc8
Added the Mac to platforms that don't have user/group/other modes.
...
Set the limit for the number of open files to 32 if platform==mac.
2003-01-08 16:30:34 +00:00
Jack Jansen
05d284b7aa
Made "ascii" the default encoding for MacPython, as suggested by MvL, and ripped out my previous changes to test_unicode. Doing this for 2.3a1 should give people enough time to complain, if they want to, and then we can see whether we want to do anything about it.
2003-01-08 16:29:17 +00:00
Jack Jansen
b8941f2dbe
Added a couple of casts to make this compile with CodeWarrior.
2003-01-08 16:28:45 +00:00
Jack Jansen
3e82872eca
Merging the various tweaks for MacPython-OS9 2.3a1 back into the trunk.
2003-01-08 16:27:44 +00:00
Thomas Heller
6c64fa7dda
Mention the change from patch #664376 .
2003-01-08 15:14:55 +00:00
Thomas Heller
27bb71e963
Patch #664376 : sys.path[0] should contain absolute pathname.
...
This fixes the problem on Windows - that's the only system where I can
test it.
It leaves sys.argv alone and only changes sys.path[0] to an absolute
pathname.
2003-01-08 14:33:48 +00:00
Fred Drake
326c72a839
Add notes about the linuxaudiodev and ossaudiodev modules.
2003-01-08 07:21:53 +00:00
Fred Drake
7511bd957d
- be explicit: audio data files should be opened in binary mode
...
- ossaudiodev.open() raises IOError, not ossaudiodev.error, for cases
which get mapped to TestSkipped
2003-01-08 07:09:43 +00:00
Neal Norwitz
55d555f012
command doesn't work, but program does, not sure it's correct, though
2003-01-08 05:27:42 +00:00
Greg Ward
19b6f60f5c
There's no such method as has_option() -- should be has_extn().
2003-01-08 03:04:42 +00:00
Greg Ward
d4fee28717
Rewrite awkward/ungrammatical sentence.
...
Typo fix.
2003-01-08 03:02:26 +00:00
Andrew M. Kuchling
d97b01cb82
Bump version number
2003-01-08 02:09:40 +00:00
Greg Ward
0a6355eb1f
Add reminder that ossaudiodev can/should also be built on FreeBSD.
2003-01-08 01:37:41 +00:00
Guido van Rossum
dca3f2f54a
Enable building and testing of ossaudiodev for Linux.
2003-01-08 01:23:01 +00:00
Guido van Rossum
cd0c047619
Note about rexec.py and Bastion.py. This requires doc changes and
...
whatsnew updates as well.
2003-01-07 23:03:05 +00:00
Barry Warsaw
b6604b3e69
Document EX_OK and friends.
2003-01-07 22:43:25 +00:00
Barry Warsaw
fe33b795d5
Test for presence of sysexits.h and set HAVE_SYSEXITS_H if so. Used
...
by posixmodule.c.
2003-01-07 22:42:49 +00:00
Neal Norwitz
051314f924
SF #664011 , move tarfile module in docs
2003-01-07 22:36:04 +00:00
Barry Warsaw
5676bd1c2d
all_ins(): EX_OK and friends, constants from sysexits.h
2003-01-07 20:57:09 +00:00
Barry Warsaw
f8ba39c4c0
A note about EX_OK and friends in the posixmodule.
2003-01-07 20:55:26 +00:00
Guido van Rossum
6d0d3655af
Fix from Michael Stone for SF bug #660476 and #513033 (bogus thread
...
state swaps in readline).
2003-01-07 20:34:19 +00:00
Guido van Rossum
05ac449d29
A few more whitespace normalizations.
2003-01-07 20:04:12 +00:00
Guido van Rossum
74f3143d18
Various cleanups:
...
- Whitespace normalization.
- Cleaned up some comments.
- Broke long lines.
2003-01-07 20:01:29 +00:00
Guido van Rossum
8b7b345328
Use regular expressions for branch matching, to avoid including
...
changes on a sub-branch into output for a given branch.
2003-01-07 16:46:24 +00:00
Guido van Rossum
373c7412f2
Fix for SF bug #642358 : only provide a new with a __dict__ or
...
__weaklist__ descriptor if we added __dict__ or __weaklist__,
respectively. With unit test.
2003-01-07 13:41:37 +00:00
Raymond Hettinger
145a4a0f10
Much clearer when super() is used.
2003-01-07 10:25:55 +00:00
Raymond Hettinger
a9cfa5501f
SF bug #652933 (for IdleFork): Open Module "math" Fails
...
When a module doesn't have a __path__ attribute, trigger a dialog box
rather than dumping a traceback to the console.
2003-01-07 09:55:03 +00:00
Raymond Hettinger
ef30dc872b
Revert change 1.37.
...
The nanoseconds saved by using dict.fromkeys aren't
worth the loss in clarity. Linear searches live on.
2003-01-07 02:09:16 +00:00
Raymond Hettinger
625812f618
SF patch #662433 : Fill arraymodule's tp_iter and sq_contains slots
2003-01-07 01:58:52 +00:00
Barry Warsaw
4e68a1ec6c
CHARSETS, ALIASES, CODEC_MAP: SF feature request 633543, Korean
...
support and other charset defaults. See also:
http://article.gmane.org/gmane.comp.python.mime.devel/250
(this just commits the last bit of the article that wasn't part of
email 2.4.3.)
2003-01-07 00:29:07 +00:00
Andrew M. Kuchling
674b0bfde6
Add tarfile module
2003-01-07 00:07:19 +00:00
Guido van Rossum
613f24fd73
Add a test for a feature added in rev. 2.82 of typeobject.c:
...
- SLOT1BINFULL() macro: changed this to check for __rop__ overriding
__op__, like binary_op1() in abstract.c -- the latter only calls the
slot function once if both types use the same slot function, so the
slot function must make both calls -- which it already did for the
__op__, __rop__ order, but not yet for the __rop__, __op__ order
when B.__class__ is a subclass of A.__class__.
Also test the refinement added in rev. 2.201 that fixes the problem
reported in SF bug #623669 .
Also test a similar provision in abstract.c's binary_op1().
2003-01-06 23:00:59 +00:00
Guido van Rossum
cd118803b5
Add a refinement to SLOT1BINFULL() that fixes the problem reported in
...
SF bug #623669 : only try (e.g.) __rdiv__ before __div__ if the right
class actually overrides it.
2003-01-06 22:57:47 +00:00
Raymond Hettinger
0a2f849b79
GvR's idea to use memset() for the most common special case of repeating
...
a single character. Shaves another 10% off the running time by avoiding
the lg2(N) loops and cache effects for the other cases.
2003-01-06 22:42:41 +00:00
Guido van Rossum
2720b0dff8
Add some print statements in verbose mode to announce that the newest
...
tests are run. (All tests in this module should have one of these at
the top.)
2003-01-06 21:26:44 +00:00