Skip to content

Conversation

@dereuromark
Copy link
Member

Summary

  • Add runtime deprecationWarning() calls to AbstractMigration and AbstractSeed
  • These classes had @deprecated 4.5.0 docblock annotations but no runtime warnings
  • Users will now see deprecation notices during execution, helping them upgrade early

Changes

  • AbstractMigration: Added setAdapter() override with deprecation warning (constructor is final in Phinx)
  • AbstractSeed: Added constructor with deprecation warning

This helps users migrate to BaseMigration and BaseSeed before the 5.0 release.

These classes have had @deprecated docblock annotations since 4.5.0, but
no runtime warnings were emitted. This adds deprecationWarning() calls
so users are notified during execution that they should migrate to
BaseMigration and BaseSeed respectively.
@dereuromark dereuromark added this to the 4.x (CakePHP 5) milestone Jan 21, 2026
@dereuromark
Copy link
Member Author

@markstory I would recommend making the necessity to update early on to new Base classes more clear to consumers and plugin maintainers. We can release this also as a minor on 4.x if needed to clarify upgrade path.

@markstory
Copy link
Member

We can release this also as a minor on 4.x if needed to clarify upgrade path.

I deleted my earlier comment after I thought a bit more. I think this is fine as is. We've had an upgrade path for a few minors already, and people on older core versions still have a path forward to no deprecations 👍

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants