Skip to content

Upgrade to veewee/xml v4 and bump minimum PHP to 8.4#22

Merged
veewee merged 1 commit intomainfrom
upgrade/veewee-xml-v4
Mar 27, 2026
Merged

Upgrade to veewee/xml v4 and bump minimum PHP to 8.4#22
veewee merged 1 commit intomainfrom
upgrade/veewee-xml-v4

Conversation

@veewee
Copy link
Copy Markdown
Member

@veewee veewee commented Mar 27, 2026

Summary

  • Bumps veewee/xml from ^3.0 to ^4.9 (uses PHP 8.4's new spec-compliant Dom\ API)
  • Drops PHP 8.3 support; minimum is now ~8.4.0 || ~8.5.0
  • Removes PHP 8.3 from all GitHub Actions matrices
  • Updates Psalm phpVersion to 8.4 and adds DOM stubs from veewee/xml 4.8+

Migration changes

  • Psr7StreamLoader: updated to new Loader interface (__invoke(): XMLDocument instead of mutating a passed DOMDocument)
  • Psr7StreamMapper: updated to new Mapper interface (parameter is now Dom\XMLDocument)
  • XmlMessageManipulator: replaced Document::configure(loader(...)) with Document::fromLoader(...)
  • All DOMDocument / DOMElement / DOMNode type hints replaced with Dom\XMLDocument / Dom\Element / Dom\Node
  • All expectAllOfType(DOMElement::class) calls updated to expectAllOfType(Element::class)

Test plan

  • PHPUnit passes locally (31 tests, 51 assertions)
  • Psalm passes with no errors, 100% type coverage
  • php-cs-fixer reports 0 fixable files
  • All tests pass in Docker (docphpro/php84 — PHP 8.4.19, libxml 2.9.14 on Ubuntu 24.04)

- Bumps veewee/xml from ^3.0 to ^4.9 (new PHP 8.4 spec-compliant DOM API)
- Drops PHP 8.3 support; minimum is now ~8.4.0 || ~8.5.0
- Removes PHP 8.3 from all GitHub Actions matrices
- Updates Psalm phpVersion to 8.4 and adds DOM stubs from veewee/xml 4.8+
- Migrates DOMDocument/DOMElement/DOMNode to Dom\XMLDocument/Dom\Element/Dom\Node
- Adapts Loader interface: __invoke() now returns XMLDocument instead of mutating one
- Adapts Mapper interface: parameter is now Dom\XMLDocument
- Replaces Document::configure(loader(...)) with Document::fromLoader(...) in XmlMessageManipulator
- Updates all expectAllOfType() calls to use Dom\Element::class
@veewee veewee force-pushed the upgrade/veewee-xml-v4 branch from 8a6f80a to 64637ad Compare March 27, 2026 11:14
@veewee veewee merged commit 34dd635 into main Mar 27, 2026
12 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant