Closed astorm closed 7 years ago
Seems you have an empty file which is parsed by the \Magento\Setup\Module\Di\Code\Reader\ClassesScanner, which uses the PHP token_get_all method. The exception is thrown, if the method does not return any value, which is the case on an empty file.
@websharp Thanks for reminding me about this ticket. I was able to track down the reason for this -- UMC users folders with a .php
extension
https://github.com/UltimateModuleCreator/Umc_Base/tree/master/etc/source/Ui/Component/Listing/Column/EntityActions.php
The setup:di:compile
command scans every directory in app/code
for PHP files. This means it processes the directory as a file, finds no tokens, and halts.
This should no longer be an issue with Magento 2.1
@maderlock Thanks for the heads up, but can you explain why?
This should be fixed in version 2.0.0-beta1
If I install this module into my system and attempt to compile my classes for production (with the
setup:di:compile
command) I end up with aerror. Full stack trace below
While this probably isn't a module you'd want to leave installed on a production system, I've found you often still to pre-generate your classes when working on a local development Magento 2 system. It would be nice if this could be fixed.