•  
      request #13939 REST test suite runner segfault when tests of external plugins are executed
    Infos
    #13939
    Thomas Gerbet (tgerbet)
    2019-09-27 10:52
    2019-09-27 09:39
    15151
    Details
    REST test suite runner segfault when tests of external plugins are executed

    Developers have encountered segfault of the REST test suite runner when playing the test suite with the additional tests of plugins not maintained inside the main repository (those tests are not at fault here).

     

    The issue seems to be related to the usage of curl_multi_select() with different handles. At the moment I did not successfully isolated the issue in a minimal test case. The fact we are running the test suite in a CentOS 6 environnement with a version of libcurl "a bit old" probably does not help.

     

    PHPUnit 8.3.4 by Sebastian Bergmann and contributors.
    Runtime: PHP 7.3.10
    Configuration: /usr/share/tuleap/tests/rest/phpunit.xml ............................................................... 63 / 988 ( 6%) ............................................................... 126 / 988 ( 12%) ............................................................... 189 / 988 ( 19%) ............................................................... 252 / 988 ( 25%) ............................................................... 315 / 988 ( 31%) ............................................................... 378 / 988 ( 38%) ............................................................... 441 / 988 ( 44%) ............................................................... 504 / 988 ( 51%) ............................................................... 567 / 988 ( 57%) ............................................................... 630 / 988 ( 63%) ............................................................... 693 / 988 ( 70%) ............................................................... 756 / 988 ( 76%) ............................................................... 819 / 988 ( 82%) ............................................................... 882 / 988 ( 89%) ............................................................... 945 / 988 ( 95%) ...................................../usr/share/tuleap/tests/rest/bin/test_suite.sh: line 5: 2890 Segmentation fault (core dumped) $PHPUNIT --configuration /usr/share/tuleap/tests/rest/phpunit.xml --do-not-cache-result --log-junit /output/rest_tests.xml $1 make: *** [Makefile:106: tests_rest_73] Error 139

     

    Stacktraces:

    #0  ZEND_DO_FCALL_BY_NAME_SPEC_RETVAL_USED_HANDLER (execute_data=0x7ffff3e24840) at /usr/src/debug/php-7.3.10/Zend/zend_vm_execute.h:908
    #1  0x0000000000669d20 in execute_ex (ex=<value optimized out>) at /usr/src/debug/php-7.3.10/Zend/zend_vm_execute.h:55338
    #2  0x00000000006bb6fb in zend_execute (op_array=<value optimized out>, return_value=<value optimized out>) at /usr/src/debug/php-7.3.10/Zend/zend_vm_execute.h:60889
    #3  0x0000000000629ee3 in zend_execute_scripts (type=8, retval=0x0, file_count=3) at /usr/src/debug/php-7.3.10/Zend/zend.c:1568
    #4  0x00000000005ca628 in php_execute_script (primary_file=0x7fffffffd0e0) at /usr/src/debug/php-7.3.10/main/main.c:2639
    #5  0x00000000006be9a9 in do_cli (argc=4, argv=0xa37af0) at /usr/src/debug/php-7.3.10/sapi/cli/php_cli.c:997
    #6  0x00000000006bf13b in main (argc=4, argv=0xa37af0) at /usr/src/debug/php-7.3.10/sapi/cli/php_cli.c:1389

     

     

     

    [0x7ffff3e24840] Guzzle\Http\Curl\CurlMulti->executeHandles() /usr/share/tuleap/tests/rest/vendor/guzzle/guzzle/src/Guzzle/Http/Curl/CurlMulti.php:242
    [0x7ffff3e24650] Guzzle\Http\Curl\CurlMulti->perform() /usr/share/tuleap/tests/rest/vendor/guzzle/guzzle/src/Guzzle/Http/Curl/CurlMulti.php:224
    [0x7ffff3e24570] Guzzle\Http\Curl\CurlMulti->send() /usr/share/tuleap/tests/rest/vendor/guzzle/guzzle/src/Guzzle/Http/Curl/CurlMulti.php:111
    [0x7ffff3e243d0] Guzzle\Http\Curl\CurlMultiProxy->send() /usr/share/tuleap/tests/rest/vendor/guzzle/guzzle/src/Guzzle/Http/Curl/CurlMultiProxy.php:94
    [0x7ffff3e242e0] Guzzle\Http\Client->send(object[0x7ffff3e24330]) /usr/share/tuleap/tests/rest/vendor/guzzle/guzzle/src/Guzzle/Http/Client.php:284
    [0x7ffff3e24220] Guzzle\Http\Message\Request->send() /usr/share/tuleap/tests/rest/vendor/guzzle/guzzle/src/Guzzle/Http/Message/Request.php:198
    [0x7ffff3e240d0] Test\Rest\RequestWrapper->getResponseByName("rest_api_tester_1", object[0x7ffff3e24130]) /usr/share/tuleap/tests/rest/lib/RequestWrapper.php:61
    [0x7ffff3e24040] RestBase->getResponseByName("rest_api_tester_1", object[0x7ffff3e240a0]) /usr/share/tuleap/tests/rest/lib/RestBase.php:183
    [0x7ffff3e23fc0] RestBase->getResponse(object[0x7ffff3e24010]) /usr/share/tuleap/tests/rest/lib/RestBase.php:163
    [0x7ffff3e23d70] Tracker\ArtifactTest->testPOSTArtifactInXMLTracker() /usr/share/tuleap/plugins/tracker/tests/rest/XML/ArtifactTest.php:164
    [0x7ffff3e238c0] PHPUnit\Framework\TestCase->runTest() /usr/share/tuleap/tests/rest/vendor/phpunit/phpunit/src/Framework/TestCase.php:1327
    [0x7ffff3e23140] PHPUnit\Framework\TestCase->runBare() /usr/share/tuleap/tests/rest/vendor/phpunit/phpunit/src/Framework/TestCase.php:947
    [0x7ffff3e22130] PHPUnit\Framework\TestResult->run(object[0x7ffff3e22180]) /usr/share/tuleap/src/vendor/phpunit/phpunit/src/Framework/TestResult.php:691
    [0x7ffff3e21670] PHPUnit\Framework\TestCase->run(object[0x7ffff3e216c0]) /usr/share/tuleap/tests/rest/vendor/phpunit/phpunit/src/Framework/TestCase.php:679
    [0x7ffff3e21010] PHPUnit\Framework\TestSuite->run(object[0x7ffff3e21060]) /usr/share/tuleap/tests/rest/vendor/phpunit/phpunit/src/Framework/TestSuite.php:568
    [0x7ffff3e209b0] PHPUnit\Framework\TestSuite->run(object[0x7ffff3e20a00]) /usr/share/tuleap/tests/rest/vendor/phpunit/phpunit/src/Framework/TestSuite.php:568
    [0x7ffff3e1e690] PHPUnit\TextUI\TestRunner->doRun(object[0x7ffff3e1e6e0], reference, true) /usr/share/tuleap/src/vendor/phpunit/phpunit/src/TextUI/TestRunner.php:616
    [0x7ffff3e1e2b0] PHPUnit\TextUI\Command->run(array(3)[0x7ffff3e1e300], true) /usr/share/tuleap/tests/rest/vendor/phpunit/phpunit/src/TextUI/Command.php:201
    [0x7ffff3e1e200] PHPUnit\TextUI\Command->main() /usr/share/tuleap/tests/rest/vendor/phpunit/phpunit/src/TextUI/Command.php:160
    [0x7ffff3e1e030] (main) /usr/share/tuleap/tests/rest/vendor/phpunit/phpunit/phpunit:61
     
     
    Dev tools
    Empty
    Empty
    • [ ] enhancement
    • [ ] internal improvement
    Empty
    Stage
    Thomas Gerbet (tgerbet)
    Closed
    2019-09-27
    Attachments
    Empty
    References

    Follow-ups

    User avatar
    Thomas Gerbet (tgerbet)2019-09-27 09:39
    • Summary
      -REST test suite runner segfault when tests of external plugins are played 
      +REST test suite runner segfault when tests of external plugins are executed