Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Improve ergonomics of invalid colum declaration exceptions #5725

Merged
merged 2 commits into from
Oct 6, 2022

Conversation

morozov
Copy link
Member

@morozov morozov commented Oct 5, 2022

Q A
Type improvement

Fixes #5645

Change summary:

  1. Introduce abstract InvalidColumnType exception class.
  2. Make all corresponding exceptions its subclasses.
  3. Introduce final InvalidColumnDeclaration exception class.
  4. In the scope where the column name is available, wrap InvalidColumnType exceptions in a InvalidColumnDeclaration.

Subsequently, InvalidColumnDeclaration exceptions could be wrapped in other exceptions that will carry additional context (e.g. the table name, the operation being performed: create, alter, etc).

@morozov morozov added this to the 4.0.0 milestone Oct 5, 2022
@morozov morozov marked this pull request as ready for review October 6, 2022 00:07
@morozov morozov requested a review from greg0ire October 6, 2022 00:07
@morozov morozov merged commit f92d354 into doctrine:4.0.x Oct 6, 2022
@morozov morozov deleted the issues/5645 branch October 6, 2022 13:47
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Oct 7, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants