After all these answers about configuration points. Sometimes this error is due to your dependency injection error at runtime. Please run your program to check for dependency error and fix DI errors. Then the migration error is removed.