输入图片描述
我使用Doctrine在我的自定义项目与PHP 7.4.6。当我尝试应用迁移时,我得到这个错误
[error] Migration appmigrationsVersion20210113120851 failed during Pre-Checks. Error: "Provided directory "C:Users836D~1AppDataLocalTemp" does not exist"
In InvalidProxyDirectoryException.php line 18:
Provided directory "C:Users836D~1AppDataLocalTemp" does not exist
如果您使用的是windows,问题可能出现在"vendor/friendsofphp/proxy-manager-lts/src/ProxyManager/FileLocator/FileLocator.php"要进行迁移,只需在构造函数中注释$absolutePath = realpath($proxiesDirectory);
行,并显式指定临时目录路径。例如:
//$absolutePath = realpath($proxiesDirectory);
$absolutePath = 'C:Temp';