You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
windows系统启动php think work:server
报错信息如下: [think\exception\ErrorException] Cannot use Workerman\Worker as Worker because the name is already in use
解决办法:
找到目录:
\vendor\topthink\think-worker\src\command\Server.php
找到命名空间:
use Workerman\Worker;
修改为:
use Workerman\Worker as Worker2;
紧接着修改 119 行与 126的 worker 改为 Worker2
windows系统启动
php think work:server
报错信息如下:
[think\exception\ErrorException] Cannot use Workerman\Worker as Worker because the name is already in use
解决办法:
找到目录:
\vendor\topthink\think-worker\src\command\Server.php
找到命名空间:
use Workerman\Worker;
修改为:
use Workerman\Worker as Worker2;
紧接着修改 119 行与 126的 worker 改为 Worker2
找到目录:
\vendor\topthink\think-worker\src\command\GatewayWorker.php
找到命名空间
use Workerman\Worker;
修改为:
use Workerman\Worker as Worker3;
linux centos系统没有以上错误
The text was updated successfully, but these errors were encountered: