Skip to content

Support doctrine/dbal 4.5 next to 4.4 - #31

Merged
veewee merged 1 commit into
phpro:mainfrom
veewee:fix/dbal-4.5-compat
Oct 12, 2026
Merged

veewee merged 1 commit into
phpro:mainfrom
veewee:fix/dbal-4.5-compat

Conversation

@veewee

@veewee veewee commented Oct 12, 2026

Copy link
Copy Markdown
Contributor

CI resolves fresh dependencies and now picks up doctrine/dbal 4.5.0 and psalm 6.20.0, which breaks main as well as open PRs such as #30.

DBAL 4.5 deprecates Column::getType() and passing a Type instance to the Column constructor, and it resolves an instance's name by identity in the type registry, so tests that built columns with new GuidType() now throw TypeNotRegistered. Because 4.4 has neither getTypeName() nor string type names, Table picks the available API at runtime instead of raising the constraint to ^4.5. The tests use the registered instances from Type::getType(), like the other tests already do.

Psalm 6.20 reports the nullsafe call in Vector as possibly null, while 6.14 reports a null fallback there as redundant, so Vector uses a plain ternary that both versions accept.

The typeOf() helper in Table can go once the constraint moves to ^4.5.

DBAL 4.5 deprecates Column::getType() and passing a Type instance to
the Column constructor, and resolves an instance's name by identity in
the type registry, so a fresh GuidType is no longer registered. 4.4 has
neither getTypeName() nor string type names, so Table picks the API at
runtime and the tests use registered instances.

Psalm 6.20 reports the nullsafe call in Vector as possibly null while
6.14 calls a null fallback redundant, so Vector uses a plain ternary.
@veewee
veewee merged commit 993f19d into phpro:main Oct 12, 2026
4 checks passed
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.

1 participant