Xdebug 3 is installed by default? breaking builds

Hello

I think that xdebug version 3 may be being installed by default now instead of version 2 is this correct?

We are finding it breaking our code coverage, we have reproduced it here.


Is there a way to downgrade xdebug? Is that even the issue?

Thanks

3 Likes

Add XDEBUG_MODE=coverage to your environment.

As of 2020-12-03, this will be fixed on https://github.com/xdebug/xdebug/pull/699 but will be released in the future, in the mean time setting XDEBUG_MODE=coverage run the tests.

# on your .travis.yml
env:
    global:
        - XDEBUG_MODE=coverage
6 Likes

This cost me a good day!
As @eclipxe13 suggested XDEBUG_MODE=coverage will solve the issue.
I would suggest (because this is a bug that will be fixed soon), to simply add it via Repository Settings in Travis as shown here, no need to modify config files in Git Repository.

Have a nice day!

4 Likes

Thanks both! That’s solved it for us. Very much appreciated.

New archives do, indeed, come with Xdebug 3.0.

In addition to the workaround indicated, you want to try specifying older TINY versions to sidestep it, say php: 7.3.24 (I think?)

I have also had good fortune in running tests with php 8.0 this morning.
However, I hit a problem with some tests failing because of xdebug 3 being now used.
In short: xdebug 3.0.0 has a bug that makes it fail tests when running tests based on phpunit-selenium or even some versions of plain phpunit - see https://bugs.xdebug.org/bug_view_page.php?bug_id=00001903.
The most simple and correct fix seems to me to make sure that xdebug 3.0.1 is installed on the php vms instead of 3.0.0

1 Like

The new 8.0 (and 8.0.0) archives we’ve just created and made available should have Xdebug 3.0.1. Please test it.

Indeed, works now

Imprint