Skip to content

[3.5] bpo-30107: don't dump core on expected test_io crash (#1235)#1344

Merged
vstinner merged 2 commits intopython:3.5from
vstinner:test_io_35
Apr 28, 2017
Merged

[3.5] bpo-30107: don't dump core on expected test_io crash (#1235)#1344
vstinner merged 2 commits intopython:3.5from
vstinner:test_io_35

Conversation

@vstinner
Copy link
Copy Markdown
Member

No description provided.

On macOS, SuppressCrashReport now redirects /usr/bin/defaults command
stderr into a pipe to not pollute stderr. It fixes a
test_io.test_daemon_threads_shutdown_stderr_deadlock() failure when
the CrashReporter domain doesn't exists. Message logged into stderr:

2017-04-24 16:57:21.432 defaults[41046:2462851]
The domain/default pair of (com.apple.CrashReporter, DialogType) does not exist
(cherry picked from commit d819ad9)
test_io has two unit tests which trigger a deadlock:

* test_daemon_threads_shutdown_stdout_deadlock()
* test_daemon_threads_shutdown_stderr_deadlock()

These tests call Py_FatalError() if the expected bug is triggered
which calls abort(). Use test.support.SuppressCrashReport to prevent
the creation on a core dump, to fix the warning:

Warning -- files was modified by test_io
  Before: []
  After:  ['python.core']
@vstinner vstinner merged commit 98c7a9e into python:3.5 Apr 28, 2017
@vstinner vstinner deleted the test_io_35 branch April 28, 2017 14:59
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants