1
votes

Hi StackOverflow community,

I'm working on a project with Sf2 and CouchDB database. I try to update my Sf2.7 to the last version, but when i update to Sf2.8, I have an error on cache clean / warmup commands.

[Symfony\Component\Debug\Exception\FatalThrowableError] Type error: Argument 1 passed to Doctrine\Common\Annotations\AnnotationReader::__construct() must be an instance of Doctrine\Common\Annotations\DocParser, instance of Doctrine\Common\Annotations\CachedReader given, called in /var/www/symfony/app/cache/dev/appDevDebugProjectContainer.php on line 766

I know that CachedReader gonna be deprecated, but I don't know where to search to solve this.

I can't find this kind of issue on GitHub couchdb-odm / odm-bundle repositories ...

Tell me if you want more informations about all versions, and thanks for your help !

Stack trace:

0 /var/www/symfony/app/cache/dev/appDevDebugProjectContainer.php(766): Doctrine\Common\Annotations\AnnotationReader->__construct(Object(Doctrine\Common\Annotations\CachedReader))

1 /var/www/symfony/app/bootstrap.php.cache(2248): appDevDebugProjectContainer->getDoctrineCouchdb_Odm_DefaultDocumentManagerService()

2 /var/www/symfony/vendor/doctrine/couchdb-odm-bundle/Doctrine/Bundle/CouchDBBundle/CacheWarmer/ProxyCacheWarmer.php(35): Symfony\Component\DependencyInjection\Container->get('doctrine_couchd...')

3 /var/www/symfony/vendor/sy in /var/www/symfony/vendor/doctrine/annotations/lib/Doctrine/Common/Annotations/AnnotationReader.php on line 176

1
Did you complete delete the cache directory?Cerad
Yes the cache is completly deleted before this.Jimmy Gaube
Did you update your vendors as well ? They might interfere.NaeiKinDus

1 Answers

0
votes

You could always overwrite the service definition and remove the argument causing the issue

<service id="doctrine_couchdb.odm.metadata.annotation_reader" class="%doctrine_couchdb.odm.metadata.annotation_reader.class%" public="false">
</service>