Handle non-builtin migration operations.

The migrations writing framework always assumes
that a migration operation lives in django.db.migrations.

This may not always be the case, especially for custom
migrations.