migrations: The metadata storage is not up to date when using MariaDBPlatform platform
Hi, when I use my custom platform that extends Doctrine\DBAL\Platforms\MariaDBPlatform
with UUID support for MariaDB 10.7+, or simply that specific MariaDBPlatform
, I get an error when I try to generate migrations with diff.
The metadata storage is not up to date, please run the sync-metadata-storage command to fix this issue.
Error is thrown at TableMetadataStorage::checkInitialization() because $this->needsUpdate($expectedTable)
is not null but this - https://code.rixafy.pro/drp3MB5j (var dump).
Temporary solution
Now I noticed that $this->platform in that class is \Doctrine\DBAL\Platforms\MariaDb1027Platform
(it’s deprecated) and not Doctrine\DBAL\Platforms\MariaDBPlatform
, so when I use this, or when I use my own platform with UUID support like this MariaDb1070Platform extends MariaDb1027Platform
it’s working.
I have also seen some advices https://stackoverflow.com/questions/62412312/symfony-makemigration-the-metadata-storage-is-not-up-to-date-please-run-the but that didn’t help, I’m using MariaDB 10.10.1.
About this issue
- Original URL
- State: closed
- Created 2 years ago
- Reactions: 1
- Comments: 16 (7 by maintainers)
I released 3.5.3 this morning
I’m going to close, let me know if I should reopen, anybody.
Wonderfull work!! Thanks
@Fabrizio1985 for sqlite on dbal 3.5.2, this should be fixed by https://github.com/doctrine/dbal/pull/5861 which has just been merged into the 3.5.x branch of DBAL (a 3.5.3 release should come soon)
DBAL 3.5.1 should fix the issue.