Commit Graph

11975 Commits

Author SHA1 Message Date
Raymond Hettinger 72ef8daa88 calendar.py gets no benefit from xrange() instead of range() 2007-05-17 01:08:04 +00:00
Brett Cannon d75f043c33 Remove the gopherlib module. It has been raising a DeprecationWarning since
Python 2.5.

Also remove gopher support from urllib/urllib2.  As both imported gopherlib the
usage of the support would have raised a DeprecationWarning.
2007-05-16 22:42:29 +00:00
Neal Norwitz b1a9b37aa8 Fix bug in marshal where bad data would cause a segfault due to
lack of an infinite recursion check.

Contributed by Damien Miller at Google.
2007-05-16 20:05:11 +00:00
Georg Brandl a09a96a544 HTML-escape the plain traceback in cgitb's HTML output, to prevent
the traceback inadvertently or maliciously closing the comment and
injecting HTML into the error page.
2007-05-15 20:19:34 +00:00
Raymond Hettinger 8be9ab8497 Small speedup. 2007-05-14 20:52:31 +00:00
Neal Norwitz cd498be90e Remove support for freebsd[23] which haven't been released since 2000
or earlier.  http://www.freebsd.org/releases/index.html
2007-05-13 21:13:42 +00:00
Georg Brandl 0c1f6fcaac Add bz2 to content encodings. 2007-05-13 08:04:07 +00:00
Raymond Hettinger a74b67e15e Better tests for posixpath.commonprefix 2007-05-11 17:59:59 +00:00
Neal Norwitz 42dd86b8e2 Deprecate os.popen* and popen2 module in favor of the subprocess module. 2007-05-11 06:57:33 +00:00
Neal Norwitz 82be218e97 Remove trailing whitespace in docstring 2007-05-11 06:56:52 +00:00
Neal Norwitz aa87fb6be4 Fix typo in docstring (the module is popen2, not 3). 2007-05-11 06:23:01 +00:00
Neal Norwitz d9841039db Don't ever report a failure when the sum of the reference count differences
are zero.  This should help reduce the false positives.

The message about references leaking is maintained to provide as much
info as possible rather than simply suppressing the message at the source.
2007-05-11 05:55:15 +00:00
Collin Winter fa9be8c289 Fix a bug in test.test_support.open_urlresource().
If the call to requires() doesn't precede the filesystem check, we get the following situation:
1. ./python Lib/test/regrtest.py test_foo # test needs urlfetch, not enabled, so skipped
2. ./python Lib/test/regrtest.py -u urlfetch test_foo # test runs
3. ./python Lib/test/regrtest.py test_foo # test runs (!)

By moving the call to requires() *before* the filesystem check, the fact that fetched files are cached on the local disk becomes an implementation detail, rather than a semantics-changing point of note.
2007-05-09 04:14:36 +00:00
Brett Cannon 229cee2d3d Deprecate BaseException.message as per PEP 352. 2007-05-05 01:34:02 +00:00
Thomas Heller 2ebc4d8054 Oops, these tests do not run on Windows CE. 2007-05-04 19:56:32 +00:00
Thomas Heller 1ad576c267 Do not truncate 64-bit pointers to 32-bit integers.
Fixes SF #1703286, will backport to release25-maint.
2007-05-04 19:54:22 +00:00
Thomas Heller 0455214f1c Fix some ctypes test crashes, when running with a debug Python
version on win64 by using proper argtypes and restype function
attributes.
2007-05-04 07:14:39 +00:00
Kristján Valur Jónsson 170eee9d6a Fix those parts in the testsuite that assumed that sys.maxint would cause overflow on x64. Now the testsuite is well behaved on that platform. 2007-05-03 20:09:56 +00:00
Armin Rigo 9790a27065 Fix for #1303614 and #1174712:
- __dict__ descriptor abuse for subclasses of built-in types
- subclassing from both ModuleType and another built-in types

Thanks zseil for the patch.
2007-05-02 19:23:31 +00:00
Vinay Sajip 70c8e8b861 Added new optional credentials argument to SMTPHandler.__init__, and smtp.login() is now called in SMTPHandler.emit() if credentials are specified. 2007-05-01 10:20:03 +00:00
Georg Brandl 09728b7ef3 Patch #1710352: add missing public functions to locale.__all__. 2007-05-01 06:08:15 +00:00
Neal Norwitz 1b59d10ce2 This gets the test working on Solaris. It seems a little hokey to me,
but the test passed on Linux and Solaris, hopefully other platforms too.
2007-04-27 06:45:32 +00:00
Kristján Valur Jónsson 94b706be35 The locale "En" appears not to be valid on windows underi VisualStudio.2005. Added "English" to the test_locale.py to make the testsuite pass for that build 2007-04-26 13:44:16 +00:00
Collin Winter cf795b49a9 Fix an issue related to the unittest conversion. 2007-04-25 21:50:25 +00:00
Collin Winter fb5b9890fb Convert test_ossaudiodev to use unittest. 2007-04-25 20:41:34 +00:00
Collin Winter f00c5b5873 Import and raise statement cleanup. 2007-04-25 18:54:36 +00:00
Collin Winter 297996b7d3 Change test_support.have_unicode to use True/False instead of 1/0. 2007-04-25 17:57:53 +00:00
Collin Winter bec754c2b5 Remove functionality from test_datetime.test_main() that does reference count checking; 'regrtest.py -R' is the way to do this kind of testing. 2007-04-25 17:37:35 +00:00
Collin Winter c2898c5a67 Standardize on test.test_support.run_unittest() (as opposed to a mix of run_unittest() and run_suite()). Also, add functionality to run_unittest() that admits usage of unittest.TestLoader.loadTestsFromModule(). 2007-04-25 17:29:52 +00:00
Neal Norwitz 0d4c06e06e Whitespace normalization. Ugh, we really need to do this more often.
You might want to review this change as it's my first time.  Be gentle. :-)
2007-04-25 06:30:05 +00:00
Georg Brandl fb4b3b77c7 Bug #1706381: Specifying the SWIG option "-c++" in the setup.py file
(as opposed to the command line) will now write file names ending in
".cpp" too.
2007-04-24 15:27:13 +00:00
Neal Norwitz 8eea9ac889 Fix SF #1703110, Incorrect example for add_password() (use uri, not host) 2007-04-24 04:53:12 +00:00
Collin Winter d0bfa74541 Remove code that hasn't been called in years. 2007-04-24 04:09:52 +00:00
Collin Winter 0fe118b957 Convert PyUnit -> unittest. 2007-04-24 03:43:46 +00:00
Facundo Batista 9fab9f103f As specified in RFC 2616, 2xx code indicates that the client's
request was successfully received, understood, and accepted.
Now in these cases no error is raised. Also fixed tests.
2007-04-23 17:08:31 +00:00
Facundo Batista 9f87128d8b Added tests for other methods of SSL object. Now we cover
all the object methods. This is the final step to close
the #451607 bug.
2007-04-22 01:18:56 +00:00
Georg Brandl 24522982d0 Bug #1704790: bind name "sys" locally in __del__ method so that it is
not cleared before __del__ is run.
2007-04-21 20:35:38 +00:00
Armin Rigo c0ba52d3fd Revert r53997 as per
http://mail.python.org/pipermail/python-dev/2007-March/071796.html .

I've kept a couple of still-valid extra tests in test_descr, but didn't
bother to sort through the new comments and refactorings added in r53997
to see if some of them could be kept.  If so, they could go in a
follow-up check-in.
2007-04-19 14:44:48 +00:00
Collin Winter c20a250170 Check the availability of the urlfetch resource earlier than before. 2007-04-16 22:10:32 +00:00
Neal Norwitz cbd9ee69ee When __slots__ are set to a unicode string, make it work the same as
setting a plain string, ie don't expand to single letter identifiers.
2007-04-14 05:25:50 +00:00
Barry Warsaw 25a3864541 Port r54805 from python25-maint branch:
Add code to read from master_fd in the parent, breaking when we get an OSError
(EIO can occur on Linux) or there's no more data to read.  Without this,
test_pty.py can hang on the waitpid() because the child is blocking on the
stdout write.  This will definitely happen on Mac OS X and could potentially
happen on other platforms.  See the comment for details.
2007-04-13 18:47:14 +00:00
Walter Dörwald 4234827e99 Fix utf-8-sig incremental decoder, which didn't recognise a BOM when the
first chunk fed to the decoder started with a BOM, but was longer than 3 bytes.
2007-04-12 10:35:00 +00:00
Žiga Seilnacht 9aba6d6905 Patch #1695862: remove the cleanup code, now that Windows buildbots are green
again.
2007-04-12 08:46:51 +00:00
Georg Brandl e2d827d7ef Patch #1698951: clarify deprecation message in rexec and Bastion 2007-04-12 07:01:19 +00:00
Raymond Hettinger 4db5fe970c SF 1193128: Let str.translate(None) be an identity transformation 2007-04-12 04:10:00 +00:00
Georg Brandl 135c3174e7 Exceptions are no longer old-style instances. Fix accordingly. 2007-04-11 19:25:11 +00:00
Raymond Hettinger 13936697f6 SF 1191699: Make slices picklable 2007-04-11 18:40:58 +00:00
Andrew M. Kuchling 400a49ba79 Add window.chgat() method, submitted via e-mail by Fabian Kreutz 2007-04-11 13:39:00 +00:00
Facundo Batista 59c5884b4c General clean-up. Lot of margin corrections, comments, some typos.
Exceptions now are raised in the new style. And a mockup class is
now also new style. Thanks Santiago Pereson.
2007-04-10 12:58:45 +00:00
Collin Winter 8341aac123 Typo fix. 2007-04-10 04:44:49 +00:00