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
the getMigratedVersions function depends on a getName() method for each migration to have in order to determine it's name.
Since AbstractMigration had an empty getName() this wasn't a problem until now.
So now when running ./meteor.phar migrations:migrate
We get PHP Fatal error: Call to undefined method DoctrineMigrations\Version20140122155355::getName() in /var/www/jadu/vendor/doctrine/migrations/lib/Doctrine/DBAL/Migrations/Version.php on line 114
The text was updated successfully, but these errors were encountered:
@skmetaly Can't see anywhere in the AbstractMigration where there is a getName() method ... Are you sure it wasn't trying to be used within the Version20140122155355 migration?
@jedkirby Found the issue.
Because of autoloading of the install vendor/ folder in some migrations ( for example ones that are using spacecraft/migrations ) composer overrides the autoloads from meteor.
This can cause issues like in this case where doctrine/migrations version differs from meteor and CMS.
We have a good case here where we can spot this issues, but there might be cases when meteor upgrades to minimum dependency of php 5.6 which will have different version of dependencies than the CMS one .
One option would be to automatically autoload the necessary classes ( for example the spacecraft/migrations package ) through a meteor extension.
https://github.com/doctrine/migrations/blob/master/lib/Doctrine/DBAL/Migrations/AbstractMigration.php
the
getMigratedVersions
function depends on agetName()
method for each migration to have in order to determine it's name.Since AbstractMigration had an empty
getName()
this wasn't a problem until now.So now when running
./meteor.phar migrations:migrate
We get
PHP Fatal error: Call to undefined method DoctrineMigrations\Version20140122155355::getName() in /var/www/jadu/vendor/doctrine/migrations/lib/Doctrine/DBAL/Migrations/Version.php on line 114
The text was updated successfully, but these errors were encountered: