[TIP] Travis.ci => tox => py.test => exited with code -11

Floris Bruynooghe flub at devork.be
Sun Jul 8 02:17:54 PDT 2018


On Sat 07 Jul 2018 at 17:27 -0400, Olemis Lang wrote:
> The py.test build step fails [1]_ with exit error code -11 . Nonetheless
> this code is not listed in py.test exit codes list [2]_ .
> Does anybody know what could be happening with py.test during this build ?
> What's py.test error code -11 about ?

Negative return codes do not come from the process (where the python
interpreter running pytest is the process here), but they indicate the
unhandled signal with which the OS has terminated the process.  In this
case `man 7 signal` tells me signal no 11 is SIGSEGV aka segmentation
fault aka "Invalid memory reference".

So the most likely explanation is that one of your go or swig layers is
allowing your python code to execute something that it shouldn't and the
bug is in those layers somewhere rather then in python or pytest.  The
traditional first step to figure this out is to enable coredumps and
then run the debugger on the coredump which will show you the stack
frames leading up to the crash and hopefully point you in the right


More information about the testing-in-python mailing list