@sgiehl opened this Issue on June 29th 2021 Member

Currently our AllTests suite is silently failing on TravisCI. See https://travis-ci.com/github/matomo-org/matomo/jobs/520002593#L792
The test that silently aborts is this one:

Already saw the same behavior while trying to fix the tests for PHP 8 in #16897

When running the UpdateTests locally on PHP 7.2, 7.4 or 8.0 it works without problems for me.

@matomo-org/core-reviewers is anyone able to reproduce the test failure locally?

Target of this issue should be to

  • [ ] Check why the build is actually green even if the test aborts
  • [ ] Check why the test fails and fix it
@diosmosis commented on July 1st 2021 Member

Looks like an error occurs on mysqli (in travis at least):

    [warnings] => Array

    [errors] => Array
            [0] => Mysqli prepare error: Table 'piwik_tests.archive_blob_2015_01' doesn't exist

    [coreError] => 1

    [deactivatedPlugins] => Array

This gets thrown as a runtime exception which I guess stops the test entirely.

@sgiehl commented on July 1st 2021 Member

This error is caused by the test on purpose. Not sure why it's a runtime exception in this case and why it works locally with MYSQLI 🤔

@diosmosis commented on July 4th 2021 Member

Haven't figured out the cause, but:

  • replacing the runtime exception w/ \Exception has no effect
  • and catching the exception in the Update command allows the test to continue
@diosmosis commented on July 5th 2021 Member

I've narrowed down the problem to something in the Application.php class in symfony console. The run() method has a try-catch, the catch is never entered, the process seems to just exit. However, in doRun() if I surround doRunCommand() and catch the exception, the tests continue. So I suspect the issue is Console::doRun()'s safemode logic.

This Issue was closed on August 10th 2021
Powered by GitHub Issue Mirror