Closed rieschl closed 3 years ago
@rieschl Do we need a class alias for this to work in both older and newer dependencies?
@asgrim The class-aliases were added in doctrine/peristence
1.3.0
, so we shouldn't need them here. But maybe we should add a dependency for doctrine/persistence
in composer.json
to reflect that. Implicitly, doctrine/peristence
>= 1.3.0
is required anyways because the DriverFactory
uses them already.
edit: composer-require-checker tells me the same 🙂
$ vendor/bin/composer-require-checker
ComposerRequireChecker 3.3.0@4063254c611acf34f1c15b29b6bcc47d2e7a9a9e
The following 19 unknown symbols were found:
+--------------------------------------------------------+--------------------+
| Unknown Symbol | Guessed Dependency |
+--------------------------------------------------------+--------------------+
| Doctrine\Common\Annotations\AnnotationReader | |
| Doctrine\Common\Annotations\AnnotationRegistry | |
| Doctrine\Common\Annotations\CachedReader | |
| Doctrine\Common\Cache\ApcuCache | |
| Doctrine\Common\Cache\ArrayCache | |
| Doctrine\Common\Cache\CacheProvider | |
| Doctrine\Common\Cache\ChainCache | |
| Doctrine\Common\Cache\FilesystemCache | |
| Doctrine\Common\Cache\MemcachedCache | |
| Doctrine\Common\Cache\PhpFileCache | |
| Doctrine\Common\Cache\PredisCache | |
| Doctrine\Common\Cache\RedisCache | |
| Doctrine\Common\Cache\WinCacheCache | |
| Doctrine\Common\Cache\ZendDataCache | |
| Doctrine\Common\EventManager | |
| Doctrine\Common\EventSubscriber | |
| Doctrine\Persistence\Mapping\Driver\AnnotationDriver | |
| Doctrine\Persistence\Mapping\Driver\FileDriver | |
| Doctrine\Persistence\Mapping\Driver\MappingDriverChain | |
+--------------------------------------------------------+--------------------+
@rieschl yeah OK, I'm a fan of adding the dependency (given we had a similar issue in #46 too because of implicit dependencies), so lets do that please and this is good to go I think :+1:
alright. I should rebase the PR to 3.1.x
, right?
alright. I should rebase the PR to
3.1.x
, right?
ah, yes please :)
Thanks @rieschl !
Since
doctrine/persistence
1.3.0
the namespace of the package was moved fromDoctrine\Common\Persistence
toDoctrine\Persistence
. The forward compatibility classes were removed in2.0.0
.This fix changes the namespace to the new one, which should work in
doctrine/persistence
>= 1.3.0