doctrine / migrations

Doctrine Database Migrations Library
https://www.doctrine-project.org/projects/migrations.html
MIT License
4.68k stars 385 forks source link

"migrate" creates migration table and --dry-run doesn't seem to output queries? #1335

Open alturic opened 1 year ago

alturic commented 1 year ago

Two quick issues, one looks like it was fixed years ago, but it seems to be back now (https://github.com/doctrine/migrations/issues/521) as fresh migrate command does create an empty migrations table?

The second is when running symfony console doctrine:migrations:migrate --dry-run I'm expecting an output of what queries will be ran, is this not the expected output? It currently just outputs:

[notice] Migrating (dry-run) up to DoctrineMigrations\Version202304010319391
[notice] finished in 9ms, used 44M memory, 1 migrations executed, 4 sql queries

 [OK] Successfully migrated to version : DoctrineMigrations\Version20230401031939

Now, if I also pass -vv it does show the queries that would be ran, but that makes me question if the docs need to be updated (https://www.doctrine-project.org/projects/doctrine-migrations/en/3.7/reference/managing-migrations.html#dry-run) and also what exactly is the purpose of --dry-run by itself as it seems to imply -vv needs to always be passed with it?