10BC0 [Maintenance] Allow doctrine/doctrine-bundle ^3.1 by Rafikooo · Pull Request #18754 · Sylius/Sylius · GitHub
[go: up one dir, main page]

Skip to content

Conversation

@Rafikooo
Copy link
Contributor
@Rafikooo Rafikooo commented Jan 28, 2026

Summary

  • Add support for doctrine/doctrine-bundle 3.x alongside 2.x (^2.13 || ^3.1)
  • Added CI matrix entries to test both versions (minimal: v2 with Sf 6.4, v3 with Sf 7.4; full: additional v3 build)

This is preparation work for future Symfony 8 support, as doctrine-bundle 3.x is required for Sf8.

Summary by CodeRabbit

  • New Features

    • Broadened compatibility: support for Doctrine Bundle 2.13+ and 3.1+, and Doctrine DBAL 3.x or 4.x.
  • Chores

    • CI matrix expanded to include Doctrine Bundle 3.1 scenarios.
    • CI workflows add an optional step to validate Doctrine Bundle restrictions in relevant test jobs.

✏️ Tip: You can customize this high-level summary in your review settings.

Add support for doctrine/doctrine-bundle 3.x alongside 2.x.
Added CI matrix entries to test both versions.
@Rafikooo Rafikooo requested review from a team as code owners January 28, 2026 15:23
@probot-autolabeler probot-autolabeler bot added the Maintenance CI configurations, READMEs, releases, etc. label Jan 28, 2026
@coderabbitai
Copy link
coderabbitai bot commented Jan 28, 2026
📝 Walkthrough

Walkthrough

Adds DoctrineBundle 3.1 compatibility by broadening composer constraints and extends CI matrix/workflows to optionally restrict and test against doctrine/doctrine-bundle versions (^2.13 and ^3.1).

Changes

Cohort / File(s) Summary
CI Workflow Configuration
.github/workflows/ci_e2e-mysql.yaml, .github/workflows/matrix.json
Adds doctrine_bundle entries to the test matrix and inserts conditional "Restrict Doctrine Bundle" composer require steps into multiple CI jobs (same pattern/conditions as existing Twig restriction).
Root composer.json
composer.json
Expands constraints: doctrine/dbal → `^3.9
Bundle composer.json files
src/Sylius/Bundle/*Bundle/composer.json (multiple bundles, e.g., Addressing, Attribute, Channel, Core, Currency, Customer, Inventory, Locale, Money, Order, Payment, Product, Promotion, Review, Shipping, Taxation, Taxonomy, User, Api)
Updated require-dev (or require where noted) constraints to accept doctrine/doctrine-bundle `^2.13

Sequence Diagram(s)

(Skipped — changes are configuration and homogeneous dependency/matrix updates that do not introduce complex multi-component control flow requiring visualization.)

Estimated code review effort

🎯 3 (Moderate) | ⏱️ ~20 minutes

Possibly related PRs

  • Orm 3 support #18049 — Modifies dependency constraints and CI/matrix to add support for newer Doctrine components; closely related to dependency/matrix changes here.

Suggested labels

Dependencies

Suggested reviewers

  • GSadee
  • mpysiak
  • NoResponseMate

Poem

🐰 I hopped through composer and CI tonight,
Pushed ^3.1 into the moonbeam light,
Bundles snugged in new-version cheer,
Tests will dance when matrix is near,
A tiny rabbit clap — compatibility delight!

🚥 Pre-merge checks | ✅ 3
✅ Passed checks (3 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title accurately reflects the primary objective of this PR: enabling support for doctrine/doctrine-bundle ^3.1 alongside existing ^2.13 support across all affected composer.json files and CI workflows.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.


Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

@github-actions
Copy link
github-actions bot commented Jan 28, 2026

❗ Preview Environment deployment failed on Bunnyshell

See: Environment Details | Pipeline Logs

Check https://github.com/Sylius/Sylius/actions/runs/21453129670 for details.

Available commands:

  • 🚀 /bns:deploy to redeploy the environment
  • /bns:delete to remove the environment

Copy link
@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1

🤖 Fix all issues with AI agents
In `@src/Sylius/Bundle/TaxationBundle/composer.json`:
- Around line 38-40: The require-dev entry for "doctrine/doctrine-bundle"
currently allows ^3.1 which is PHP ^8.4-only; update composer.json to prevent
installation on PHP 8.2/8.3 by either removing the "|| ^3.1" from the
"doctrine/doctrine-bundle" requirement (leave it as "^2.13") or keep the
requirement but add a "conflict" entry for "doctrine/doctrine-bundle": "^3.1"
when the package is used with PHP <8.4 — modify the "require-dev" and/or add a
top-level "conflict" key referencing "doctrine/doctrine-bundle" so
DoctrineBundle 3.1 cannot be installed on unsupported PHP versions.

Comment on lines 38 to 40
"require-dev": {
"doctrine/doctrine-bundle": "^2.13",
"doctrine/doctrine-bundle": "^2.13 || ^3.1",
"doctrine/orm": "^2.18 || ^3.5",
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Potential issue | 🟠 Major

🧩 Analysis chain

🌐 Web query:

doctrine/doctrine-bundle 3.1 requirements PHP Symfony version compatibility

💡 Result:

I wasn’t able to retrieve the version-specific require constraints for DoctrineBundle 3.1.x (e.g., 3.1.0 / 3.1.1) from Packagist/GitHub in a way that exposes the composer.json contents reliably in this environment (Packagist only rendered the latest requirements; GitHub file views didn’t render the raw file content).

What I can confirm from authoritative sources is:

  • DoctrineBundle 3.1.x exists and was released as:
    • 3.1.0 on 2025-11-29
    • 3.1.1 on 2025-12-21 (marked “unmaintained” in Doctrine’s docs site for that version line) [1]
  • Latest available DoctrineBundle (currently 3.2.2) requires:
    • PHP ^8.4
    • Symfony components ^6.4 || ^7.0 || ^8.0 (incl. symfony/framework-bundle, symfony/cache, etc.) [2]

If you tell me whether you mean 3.1.0 or 3.1.1, and what Symfony/PHP versions you’re targeting, I can help you pick a compatible DoctrineBundle line (e.g., 2.19.x vs 3.0.x vs 3.1.x vs 3.2.x) based on the constraints you have.

Sources: [1] [2]


🏁 Script executed:

# Check the composer.json file to understand the bundle's PHP and Symfony constraints
cat src/Sylius/Bundle/TaxationBundle/composer.json | head -50

Repository: Sylius/Sylius

Length of output: 143


🏁 Script executed:

# Try a simpler read of the composer.json
head -50 src/Sylius/Bundle/TaxationBundle/composer.json

Repository: Sylius/Sylius

Length of output: 1547


🌐 Web query:

DoctrineBundle 3.1.0 3.1.1 minimum PHP version requirement

💡 Result:

I couldn’t reliably extract the PHP requirement for doctrine/doctrine-bundle 3.1.0 / 3.1.1 from upstream metadata during this lookup because Packagist/GitHub wouldn’t serve the version-specific composer.json contents in a way that was accessible via the web fetches I can run right now (the pages loaded without the file body).

What I can confirm is that Doctrine lists these releases as: 3.1.0 (2025-11-29) and 3.1.1 (2025-12-21). [1]

To get the exact minimum PHP version locally (authoritative, straight from Composer metadata), run one of:

composer show doctrine/doctrine-bundle 3.1.0 --all
composer show doctrine/doctrine-bundle 3.1.1 --all

and look under the requires section for php.

(For reference, the current Packagist page shows doctrine/doctrine-bundle 3.2.2 requires php: ^8.4, but that does not prove the requirement for 3.1.x.) [2]

Sources:
[1] Doctrine project release list for DoctrineBundle 3.1.x: https://www.doctrine-project.org/projects/doctrine-bundle/3.1.html
[2] Packagist package page (shows requirements for latest release shown on the page): https://packagist.org/packages/doctrine/doctrine-bundle


🏁 Script executed:

#!/bin/bash
# Query DoctrineBundle 3.1.0 and 3.1.1 for their PHP requirements
composer show doctrine/doctrine-bundle 3.1.0 --all 2>/dev/null | grep -A 10 "requires"
echo "---"
composer show doctrine/doctrine-bundle 3.1.1 --all 2>/dev/null | grep -A 10 "requires"

Repository: Sylius/Sylius

Length of output: 1360


Remove ^3.1 or add a conflict constraint: DoctrineBundle 3.1.x requires PHP ^8.4, but this bundle supports PHP ^8.2. The constraint "doctrine/doctrine-bundle": "^2.13 || ^3.1" allows DoctrineBundle 3.1 to be installed with PHP 8.2 and 8.3, which is incompatible. Either narrow the constraint to "^2.13" only or add a conflict: "conflict": { "doctrine/doctrine-bundle": "^3.1" } when PHP <8.4.

🤖 Prompt for AI Agents
In `@src/Sylius/Bundle/TaxationBundle/composer.json` around lines 38 - 40, The
require-dev entry for "doctrine/doctrine-bundle" currently allows ^3.1 which is
PHP ^8.4-only; update composer.json to prevent installation on PHP 8.2/8.3 by
either removing the "|| ^3.1" from the "doctrine/doctrine-bundle" requirement
(leave it as "^2.13") or keep the requirement but add a "conflict" entry for
"doctrine/doctrine-bundle": "^3.1" when the package is used with PHP <8.4 —
modify the "require-dev" and/or add a top-level "conflict" key referencing
"doctrine/doctrine-bundle" so DoctrineBundle 3.1 cannot be installed on
unsupported PHP versions.

Required by doctrine/doctrine-bundle 3.x.
@probot-autolabeler probot-autolabeler bot added the API APIs related issues and PRs. label Jan 28, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

API APIs related issues and PRs. Maintenance CI configurations, READMEs, releases, etc.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant

0