Commit Graph

11496 Commits

Author SHA1 Message Date
Collin Winter b9678e71f3 1/0 -> True/False cleanup. 2007-08-30 18:11:17 +00:00
Thomas Heller bd315c54dd Calling execvp with an empty argument list raises ValueError, but we
want to test for OSError.
2007-08-30 17:57:21 +00:00
Guido van Rossum 080b2b252e Enable the trunc() test. 2007-08-30 17:46:57 +00:00
Guido van Rossum 1daf954dcf Add numbers.py. I suspect this is an old version, but Jeffrey is out
of town, and it will have to do for now.
2007-08-30 17:45:54 +00:00
Thomas Heller 6790d606ff Forbid an empty argument list in execv call.
Fixes issue 1039.
2007-08-30 17:15:14 +00:00
Barry Warsaw 2cc1f6d95b More email package related repairs. This fixes smtplib's import and use of
email.base64mime, but test_smtplib still has failures for me.  They are
timeout errors so think they're more related to my current wacky network setup
than bugs remaining in the code related to the email package.

This also r57693 that got clobbered with the sandbox sync, and fixes a couple
of other minor problems that cropped up.  I will kill the sandbox branch next.

The email package now has 11F/11E.
2007-08-30 14:28:55 +00:00
Guido van Rossum 5a23cc5a01 Two changes (not enough to make the test pass though) having to do with
the bytes() constructor when passing str.
2007-08-30 14:02:43 +00:00
Martin v. Löwis a79f1254ff Stop testing for encoded file names, as Python 3 does
not support them, anyway.
2007-08-30 10:08:57 +00:00
Neal Norwitz eaa16f9737 Try to fix test_plistlib so it uses bytes consistently in this call 2007-08-30 06:37:08 +00:00
Kurt B. Kaiser 152b3c2170 Use inspect.py and clean up. 2007-08-30 06:35:15 +00:00
Neal Norwitz f40080f247 Try to fix test_aepack by comparing bytes with bytes. 2007-08-30 06:32:09 +00:00
Neal Norwitz 9a92310f87 Write bytes instead of unicode 2007-08-30 06:20:05 +00:00
Neal Norwitz 78a70bd870 Try to get test_pep352 and maybe test_platform to work on a Windows buildbot 2007-08-30 06:16:26 +00:00
Neal Norwitz 09cff641b8 Since the filename is encoded, we must add bytes to it. The test
still fails, but gets a little further with this change.
2007-08-30 05:59:15 +00:00
Neal Norwitz cabac0ac3a Stop using the find function on the string module, use the string method.
This will hopefully fix the problem on a Windows buildbot with test_sundry.
2007-08-30 05:35:41 +00:00
Neal Norwitz c247e51e68 Make this module importable, this gets test___all__ to pass. 2007-08-30 05:19:29 +00:00
Collin Winter 5b7e9d76f3 General cleanup, raise normalization in Lib/distutils. 2007-08-30 03:52:21 +00:00
Collin Winter a73bfee73d Raise statement normalization in Lib/ctypes/. 2007-08-30 03:47:13 +00:00
Guido van Rossum 9604e66660 Oops. I copied a slightly older version of the email package from the sandbox.
This should restore the email package in the py3k branch to exactly what's in
the sandbox.

This wipes out 1-2 fixes made post-copy, which I'll re-apply shortly.
2007-08-30 03:46:43 +00:00
Neal Norwitz 2c440a1086 Use the new name for the parser module. 2007-08-30 03:10:46 +00:00
Neal Norwitz 315d845739 Revert revisions 57472, 57474, and 57477 which disabled some tests
when the email package was removed.  Email was restored, so restore the tests.
2007-08-30 03:06:59 +00:00
Barry Warsaw 8b3d659692 Fix a more bytes/str confusion.
Use str.encode('raw-unicode-escape') consistently instead of bytes(string).

Remove the convert_eols argument from base64mime.decode().  This matches
previous API changes done to the quoprimime module.
2007-08-30 02:10:49 +00:00
Collin Winter ce36ad8a46 Raise statement normalization in Lib/. 2007-08-30 01:19:48 +00:00
Guido van Rossum 8b3febef2f Copying the email package back, despite its failings. 2007-08-30 01:15:14 +00:00
Collin Winter 95fb569f46 Revert r57685 (weird merge result). 2007-08-29 23:41:34 +00:00
Collin Winter 3add4d78ff Raise statement normalization in Lib/test/. 2007-08-29 23:37:32 +00:00
Collin Winter e0281cab81 2007-08-29 23:37:10 +00:00
Guido van Rossum f7f3deb702 Andother bytes/str comparison caught by Jeremy's change. 2007-08-29 20:24:57 +00:00
Jeremy Hylton 9ff05b269f Change string literal to bytes. 2007-08-29 19:09:54 +00:00
Jeremy Hylton 88d06a7240 Make terminator constants bytes. 2007-08-29 19:08:30 +00:00
Jeremy Hylton a5dc3db3d1 Change string literals to bytes, since they are compared to bytes. 2007-08-29 19:07:40 +00:00
Jeremy Hylton 18c3ff887f Make it an error to compare a bytes object and a Unicode object. 2007-08-29 18:47:16 +00:00
Guido van Rossum 991bf5d8c8 Patch # 1050 by Amaury Forgeot d'Arc.
On Windows, debug builds insert stack probes, and recursive functions
tend to exhaust the stack faster.
This patch reduces the marshal maximum depth from 2000 to 1500 for debug
builds only. Optimized builds are not affected.
This allows test_marshal to pass with debug builds.
2007-08-29 18:44:54 +00:00
Kurt B. Kaiser cf3c4217c7 1. Debugger was failing to start due to DictProxy limitations.
2. Fix some debug prints in RemoteDebugger.py - use py3k syntax.
2007-08-29 18:44:24 +00:00
Guido van Rossum fb67be2f6b Three patches from issue #1047, by Amaury Forgeot d'Arc:
1/ getargs.diff adds the 'Z' and 'Z#' format specifiers for
PyArg_ParseTuple. They mimic z and z# for unicode strings, by accepting
a Unicode or None (in which case the Py_UNICODE* pointer is set to
NULL). With doc and tests.

2/ subprocess.diff converts file PC/_subprocess.c to unicode. We use the
Unicode version of the win32 api (and Z conversion from previous patch)

3/ stdout.diff: sys.stdout must not convert the line endings, Windows
already does it.
Without this patch, when redirecting the output of python, the file
contains \r\r\n for each line. (test_subprocess did catch this)

However, I (GvR) removed the change to _fileio.c (included in the
patches) that prevents closing file descripors < 3 from being closed;
I think that needs to be solved in a different way.
2007-08-29 18:38:11 +00:00
Guido van Rossum e86254e256 In rseponse to bug# 1029, force the newline default for StringIO to "\n",
so that even on Windows, after s.write("x\n"), s.getvalue() == "x\n".
2007-08-29 18:31:16 +00:00
Guido van Rossum dcce8391d1 Insist that the argument to TextIOWrapper.write() is a basestring
instance.  This was effectively already the case, but the error
reporting was lousy.
2007-08-29 18:10:08 +00:00
Jeremy Hylton da3f228740 Convert various string literals to bytes. 2007-08-29 17:26:34 +00:00
Jeremy Hylton b4df71f095 Fix test failures caused by missing/incorrect conversion to bytes. 2007-08-29 14:56:40 +00:00
Guido van Rossum 8136014862 Fix up brokenness with hashing, now hashlib is strict in requiring bytes too. 2007-08-29 14:26:52 +00:00
Guido van Rossum 04c70ad971 Fix the one failing test (can't decode twice). 2007-08-29 14:04:40 +00:00
Guido van Rossum 9befa93b04 Fix test_pyclbr -- _https_connection is optional. 2007-08-29 13:35:11 +00:00
Guido van Rossum 8c7461480b Fix failure in error handler -- exc[-1] -> exc.args[-1]. 2007-08-29 13:18:47 +00:00
Neal Norwitz 39dce30b4c Get test_bsddb3 passing 2007-08-29 05:52:49 +00:00
Gregory P. Smith e14841c19e strings vs bytes, bytes wins again 2007-08-29 05:06:13 +00:00
Guido van Rossum a74184eb1d Commit strict str/bytes distinction.
From now on, trying to write str to a binary stream
is an error (I'm still working on the reverse).
There are still (at least) two failing tests:
- test_asynchat
- test_urllib2_localnet
but I'm sure these will be fixed by someone.
2007-08-29 04:05:57 +00:00
Guido van Rossum 245b42ec4b Found a different, more direct way to disable ssl support until it's fixed. 2007-08-29 03:59:57 +00:00
Guido van Rossum 1b81e7bea5 Change the way the encoding parameter is handled.
This fixes test_doctest with strict bytes/str.
2007-08-29 03:53:53 +00:00
Guido van Rossum a1c42a92db Make test_cmd_line work with strict str/bytes. 2007-08-29 03:47:36 +00:00
Guido van Rossum a8be92b649 Fix the sqlite test. Blobs should be created using buffer(b"blob"),
not buffer("blob").
2007-08-29 03:44:33 +00:00