tl_survey.php line 17 / Did you forget a "use" statement for another namespace?
Closed this issue · 5 comments
While trying to rebuild the Contao cache the warmup stops with the error message:
CRITICAL [console] Error thrown while running command "cache:warmup --env=prod". Message: "Class 'Doctrine\DBAL\Platforms\MySqlPlatform' not found" ["exception" => Error { …},"command" => "cache:warmup --env=prod","message" => "Class 'Doctrine\DBAL\Platforms\MySqlPlatform' not found"]
In tl_survey.php line 17:
Attempted to load class "MySqlPlatform" from namespace "Doctrine\DBAL\Platforms".
Did you forget a "use" statement for another namespace?
Reproducible in Contao 4.9 and Contao 4.13
I ran into the same issue in one of my installations - BUT, I just installed a fresh Contao 4.13.28 with PHP 8.2.5 and had no problem during the installation.
hmmm... unfortunately I cannot reproduce this (yet). I have tested the following
PHP 7.4 + Contao 4.9.42 -> OK
PHP 8.0.20 + Contao 4.9.42 -> OK
PHP 8.0.20 + Contao 4.13.29 -> OK
PHP 8.1.17 + Contao 4.9.42 -> OK
PHP 8.1.17 + Contao 4.13.29 -> OK
Do you have more information about the installation environment?
best regards - Christian
This is an issue with different doctrine versions if I remember correctly. There were a small change in den class namespac between 2 and 3.
Would it be helpful to see the problem live in action?
I could show you the attempt to install the extension in a project of mine via Teams, Zoom or something like that.