Commit Graph

91522 Commits

Author SHA1 Message Date
Vinay Sajip 14b1b486ca Fixes #25097: Merged fix from 3.5. 2015-10-01 20:39:30 +01:00
Vinay Sajip d5963e615d Fixes #25097: Merged fi from 3.4. 2015-10-01 20:38:53 +01:00
Vinay Sajip 223349cfb8 Fixes #25097: Windows test is skipped if there are insufficient privileges, rather than failing. 2015-10-01 20:37:54 +01:00
Victor Stinner 98f223dfa0 Issue #25277: Set a timeout of 10 minutes in test_eintr using faulthandler to
try to debug a hang on the FreeBSD 9 buildbot.

Run also eintr_tester.py with python "-u" command line option to try to get the
full output on hang/crash.
2015-10-01 13:16:43 +02:00
Vinay Sajip 2c6ea295ba Closes #25185: merged fix from 3.5. 2015-10-01 11:28:34 +01:00
Vinay Sajip 2934fd66ae Closes #25185: merged fix from 3.4. 2015-10-01 11:27:57 +01:00
Vinay Sajip f223c53218 Closes #25185: Use UTF-8 encoding when reading pyvenv.cfg. 2015-10-01 11:27:00 +01:00
Serhiy Storchaka f22d8080ae Issue #25280: Import trace messages emitted in verbose (-v) mode are no
longer formatted twice.
2015-10-01 11:55:52 +03:00
Serhiy Storchaka 0b40aab6f0 Issue #25280: Import trace messages emitted in verbose (-v) mode are no
longer formatted twice.
2015-10-01 11:40:22 +03:00
Serhiy Storchaka f731bc09fa Issue #25280: Import trace messages emitted in verbose (-v) mode are no
longer formatted twice.
2015-10-01 11:08:50 +03:00
Victor Stinner 0e25a8f225 Merge 3.5 2015-10-01 10:01:31 +02:00
Victor Stinner 861f067201 Merge 3.4 (os.urandom) 2015-10-01 10:00:23 +02:00
Victor Stinner 78cc2e8968 Issue #25003: os.urandom() doesn't use getentropy() on Solaris because
getentropy() is blocking, whereas os.urandom() should not block. getentropy()
is supported since Solaris 11.3.
2015-10-01 09:59:32 +02:00
Victor Stinner 4d45be776c Merge 3.5 2015-10-01 09:51:02 +02:00
Victor Stinner bae2d6203f Issue #25003: On Solaris 11.3 or newer, os.urandom() now uses the getrandom()
function instead of the getentropy() function. The getentropy() function is
blocking to generate very good quality entropy, os.urandom() doesn't need such
high-quality entropy.
2015-10-01 09:47:30 +02:00
Victor Stinner 4241bcd4e1 (Merge 3.5) Issue #25274: test_recursionlimit_recovery() of test_sys now checks
sys.gettrace() when the test is executed, not when the module is loaded.

sys.settrace() may be after after the test is loaded.
2015-10-01 08:56:54 +02:00
Victor Stinner 87bddbac9d (Merge 3.4) Issue #25274: test_recursionlimit_recovery() of test_sys now checks
sys.gettrace() when the test is executed, not when the module is loaded.

sys.settrace() may be after after the test is loaded.
2015-10-01 08:56:27 +02:00
Victor Stinner 3f18f10f39 Issue #25274: test_recursionlimit_recovery() of test_sys now checks
sys.gettrace() when the test is executed, not when the module is loaded.

sys.settrace() may be after after the test is loaded.
2015-10-01 08:55:33 +02:00
Andrew Svetlov a91b7e0dc7 Merge 3.5 -> default 2015-10-01 09:49:03 +03:00
Andrew Svetlov 313242aa03 Merge 3.4 -> 3.5 2015-10-01 09:48:36 +03:00
Andrew Svetlov 1c62b52c3f Reflect parameter name change in the doc 2015-10-01 09:48:08 +03:00
Victor Stinner b7a8af20ff Fix _PyTime_AsTimevalStruct_impl() on OpenBSD
On the x86 OpenBSD 5.8 buildbot, the integer overflow check is ignored. Copy
the tv_sec variable into a Py_time_t variable instead of "simply" casting it to
Py_time_t, to fix the integer overflow check.
2015-10-01 08:44:03 +02:00
Raymond Hettinger 0d30940dd2 Add fast paths to deque_init() for the common cases 2015-09-30 23:15:02 -07:00
Victor Stinner a53a818c3c Fix regrtest --coverage on Windows
Issue #25260: Fix ``python -m test --coverage`` on Windows. Remove the list of
ignored directories.
2015-10-01 00:53:09 +02:00
Victor Stinner c29f399e7e Backout change 28d3bcb1bad6: "Try to fix _PyTime_AsTimevalStruct_impl() on
OpenBSD", I'm not sure that the change was really needed. I read the test
result of an old build because the OpenBSD was 100 builds late.
2015-09-30 22:50:12 +02:00
Victor Stinner c51d244fc9 Issue #25171: Fix compilation issue on OpenBSD in random.c
Patch written by Remi Pointel.
2015-09-30 22:06:51 +02:00
Victor Stinner d69dd8bd5e (Merge 3.5) Issue #25182: Fix compilation on Windows 2015-09-30 15:03:50 +02:00
Victor Stinner ae86da9b20 (Merge 3.4) Issue #25182: Fix compilation on Windows 2015-09-30 15:03:31 +02:00
Victor Stinner 89719e1daf Issue #25182: Fix compilation on Windows
Restore also errno value before calling PyErr_SetFromErrno().
2015-09-30 15:01:34 +02:00
Serhiy Storchaka 85c386dee4 Issue #25182: The stdprinter (used as sys.stderr before the io module is
imported at startup) now uses the backslashreplace error handler.
2015-09-30 15:51:01 +03:00
Serhiy Storchaka 008fc77e1e Issue #25182: The stdprinter (used as sys.stderr before the io module is
imported at startup) now uses the backslashreplace error handler.
2015-09-30 15:50:32 +03:00
Serhiy Storchaka a59018c7ab Issue #25182: The stdprinter (used as sys.stderr before the io module is
imported at startup) now uses the backslashreplace error handler.
2015-09-30 15:46:53 +03:00
Victor Stinner 9a14214aee Issue #25220: Fix "-m test --forever"
* Fix "-m test --forever": replace _test_forever() with self._test_forever()
* Add unit test for --forever
* Add unit test for a failing test
* Fix also some pyflakes warnings in libregrtest
2015-09-30 13:51:17 +02:00
Raymond Hettinger 38031143fb Add an early-out for deque_clear() 2015-09-29 22:45:05 -07:00
Victor Stinner 17f9716676 Issue #25220, libregrtest: more verbose output for -jN
When the -jN command line option is used, display tests running since at least
30 seconds every minute.
2015-09-30 03:05:43 +02:00
Victor Stinner b40843546b Issue #25220, libregrtest: Cleanup
No need to support.verbose in Regrtest.run_tests(), it's always set in
runtest().
2015-09-30 02:39:22 +02:00
Victor Stinner 6f20a2e01f Issue #25220, libregrtest: Pass directly ns to runtest()
* Remove runtest_ns(): pass directly ns to runtest().
* Create also Regrtest.rerun_failed_tests() method.
* Inline again Regrtest.run_test(): it's no more justified to have a method
2015-09-30 02:32:11 +02:00
Victor Stinner a204502dbf Issue #25220, libregrtest: Set support.use_resources in setup_tests()
* Rename setup_python() to setup_tests()
* Remove use_resources parameter of runtest()
2015-09-30 02:17:28 +02:00
Victor Stinner 00b8f9bb9e Issue #25274: Workaround test_sys crash just to keep buildbots usable 2015-09-30 02:02:49 +02:00
Victor Stinner ecef622fec Issue #25220, libregrtest: Call setup_python(ns) in the slaves
Slaves (child processes running tests for regrtest -jN) now inherit
--memlimit/-M, --threshold/-t and --nowindows/-n options.

* -M, -t and -n are now supported with -jN
* Factorize code to run tests.
* run_test_in_subprocess() now pass the whole "ns" namespace to the child
  process.
2015-09-30 01:39:28 +02:00
Victor Stinner 8bb19f094b Issue #25220, libregrtest: Add runtest_ns() function
* Factorize code to run tests.
* run_test_in_subprocess() now pass the whole "ns" namespace to the child
  process.
2015-09-30 01:32:39 +02:00
Victor Stinner 234cbef39f Issue #25220, libregrtest: Move setup_python() to a new submodule 2015-09-30 01:13:53 +02:00
Victor Stinner c7eab0528c Issue #25220, libregrtest: Cleanup setup code 2015-09-30 00:59:35 +02:00
Victor Stinner f33536c430 Issue #25220: Use print(flush=True) in libregrtest 2015-09-30 00:48:27 +02:00
Victor Stinner 76f756d934 Issue #25220: Enhance regrtest -jN
Running the Python test suite with -jN now:

- Display the duration of tests which took longer than 30 seconds
- Display the tests currently running since at least 30 seconds
- Display the tests we are waiting for when the test suite is interrupted

Clenaup also run_test_in_subprocess() code.
2015-09-30 00:33:29 +02:00
Victor Stinner 02319804ea Don't strip refcount in libregrtest/runtest_mp.py
Python doesn't display the refcount anymore by default. It only displays it
when -X showrefcount command line option is used, which is not the case here.
regrtest can be run with -X showrefcount, the option is not inherited by child
processes.
2015-09-29 23:52:33 +02:00
Victor Stinner 86e8c31b8d Issue #25220, libregrtest: Remove unused import 2015-09-29 23:50:19 +02:00
Victor Stinner 6448b8041a Issue #25220: truncate some long lines in libregrtest/*.py 2015-09-29 23:43:33 +02:00
Victor Stinner 37554525aa Issue #25220: regrtest setups Python after parsing command line options 2015-09-29 23:37:14 +02:00
Victor Stinner bd1a72c455 Issue #25220: Enhance regrtest --coverage
Add a new Regrtest.run_test() method to ensure that --coverage pass the same
options to the runtest() function.
2015-09-29 23:36:27 +02:00