Error in `getValidAliases()` when running with swoole installed
TimoFrenzel opened this issue · 1 comments
TimoFrenzel commented
Since the package cannot work with swoole,
It would make sense in the Generator.php method getValidAliases()
Not only to skip predis, but also swoole.
if ($facade == 'SwooleTW\Http\Server\Facades\Server' && $name == 'Server' && !class_exists('Swoole\Http\Server')) {
continue;
}
mfn commented
I understand this pattern is also used this way, e.g.
laravel-ide-helper/src/Generator.php
Lines 151 to 153 in 9f5670b
Isn't there a way to more generically solve this?
Can you show a complete stacktrace? Maybe it's smarter to just add a try/catch in the foreach
and emit a brief console message (instead of aborting) everything, WDYT?