Not working as expected
bus-factor opened this issue · 2 comments
I just found this useful package and wanted to generate a baseline for my project.
As far as I can tell, the report file isn't generated properly: it's missing the and also the sorrounding tags. The baseline file only contains tags.
Am I missing something?
When running the report generation, the process hangs forever when reaching 100%. Maybe the final step where the tags are written in the ... format is never executed and as a consequence the actual phpcs run is unable to pick up the baseline items properly.
Hi. My guess your project is very large? The standard behavior of the phpcs report writer (not specifically this package) is that it will write to the output file continuously and at the very end add a header and footer (if needed) to the output file. The same behavior is expected for the baseline report. If the process terminates prematurely, the header and footer for the xml is not created. We've been using the baseline for quite some time now, without issues. My best recommendation would be is to find out why the process is forever. Make sure xdebug is off. To run phpcs without xdebug: php -dxdebug.mode=off vendor/bin/phpcs ...
Thanks for the quick response!
I guess I'll dig into it tomorrow. The project is quite big but phpcs terminates properly within 6 minutes without the baseline report. I'm happy to open a PR or drop a line once I sorted out what's causing this behavior.