theseer / phpdox

Documentation generator for PHP Code using standard technology (SRC, DOCBLOCK, XML and XSLT)
http://phpdox.de
Other
601 stars 121 forks source link

Does not work with x-debug 3 neither with php 8.0.1 #410

Closed joaomfrebelo closed 3 years ago

joaomfrebelo commented 3 years ago

With php_xdebug-3.0.2-8.0-vs16-nts-x86_64.dll enable gives the error:

PHP Version: 8.0.1 (WINNT) PHPDox Version: 0.12.0 Exception: Error (Code: 0) Location: phar://C:/Users/joao/.phive/phars/phpdox-0.12.0.phar/phpdox/shared/Environment.php (Line 46)

Call to undefined function TheSeer\phpDox\xdebug_disable()

0 phar://C:/Users/joao/.phive/phars/phpdox-0.12.0.phar/phpdox/CLI.php(50): TheSeer\phpDox\Environment->ensureFitness()

1 C:\Users\joao.phive\phars\phpdox-0.12.0.phar(485): TheSeer\phpDox\CLI->run()

Disabling the x-debug extension the error is;

PHP Version: 8.0.1 (WINNT) PHPDox Version: 0.12.0 ErrorException: E_COMPILE_ERROR Location: phar://C:/Users/joao/.phive/phars/phpdox-0.12.0.phar/vendor /theseer/fxsl/src/fxsltprocessor.php (Line 187)

Declaration of TheSeer\fXSL\fXSLTProcessor::transformToDoc($node) mus t be compatible with XSLTProcessor::transformToDoc(object $document, ?string $returnClass = null)

No stacktrace available

jcfalcone commented 3 years ago

Any feedback on this one?

theseer commented 3 years ago

The xdebug issue part of this ticket is a duplicate if #409. For now, please disable xdebug while running phpDox or use the master branch rather than the release.

The XSLProcessor part of this ticket is a BC break in PHP: For reasons I do not yet understand, the signatures got changed to require a generic object type rather than a specific DOMNode or DOMDocument. I consider that a bug in PHP, as passing anything else than a DOMNode makes no sense whatsoever. I'll see what can be done for that.

theseer commented 3 years ago

Okay, this cannot be fixed in a way that also works for PHP 7: The signatures are simply incompatible between 7.x and 8.x.

theseer commented 3 years ago

Please try with current master.

theseer commented 3 years ago

I'll try to make a new release later this weekend.