-
-
Notifications
You must be signed in to change notification settings - Fork 1.3k
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
Library is not compatible with doctrine/dbal ^4 #2809
Comments
It is also defined in DoctrineExtensions/composer.json Line 74 in 8d658b4
However, in your first copy / paste, we can see 🤔
The bug can be reproduced with |
Fixed by #2759 |
Oh, I see. v3.14 doesn't have that conflict definition: DoctrineExtensions/composer.json Line 72 in 3b5b5cb
So, since v3.15 defines I don't think there's a way to fix this without deleting the v3.14.0 tag and creating it again with the conflict corrected in Closing, since I don't think there's anything you can do. In the meantime, I've removed gedmo/doctrine-extensions. I'll reinstall it when there's a version that will work with doctrine/dbal version 4. 😃 |
Yeah, unfortunately, there is a lot of legacy stuff that either wasn't cleaned up fast enough (not having high version conflicts on the ORM and DBAL long before the new major versions were released) or has user data-related changes (#2502) which is going to make that a longer process to see through 😅 |
Environment
Package
show
Doctrine packages
show
PHP version
Subject
While attempting to use gedmo/doctrine-extensions in a project, specifically for
Timestampable
, I encountered an error that revealed gedmo/doctrine-extensions depends on doctrine/dbal but does not declare it inrequire
incomposer.json
(it is only declared inrequire-dev
for version^3.2
).My project uses doctrine/dbal
^4
, which definesDoctrine\DBAL\Driver::getDatabasePlatform()
as requiring one argument:Doctrine\DBAL\ServerVersionProvider $versionProvider
(see the source code for v4.0.2 here).gedmo/doctrine-extensions calls this method in the following classes but does not provide an argument:
Gedmo\SoftDeleteable\Mapping\Event\Adapter\ORM
(line 45 in v3.15.0)Gedmo\Timestampable\Mapping\Event\Adapter\ORM
(line 45 in v3.15.0)Minimal repository with the bug
n/a
Steps to reproduce
If necessary, I can create a separate repository to reproduce this bug and show it working. However, I'm not sure that's needed, since I'm able to point out what's causing the bug.
The bug is caused by use of doctrine/dbal version 4 with gedmo/doctrine-extensions version 3 and is the result of a changed interface between versions 3 and 4 of doctrine/dbal.
Expected results
gedmo/doctrine-extensions should disallow installation with doctrine/dbal version 4.
In other words, gedmo/doctrine-extensions should move
"doctrine/dbal": "^3.2"
fromrequire-dev
torequire
in itscomposer.json
.Alternately, gedmo/doctrine-extensions should update its code to work with both versions of doctrine/dbal, but in either case, doctrine/dbal should be promoted to the
require
list for the package (instead of remaining inrequire-dev
).Actual results
When responding to a Doctrine event:
The text was updated successfully, but these errors were encountered: