absolute-quantum / DoctrineEncryptBundle

:key: Encrypted symfony entities by verified and standardized libraries
https://packagist.org/packages/michaeldegroot/doctrine-encrypt-bundle
MIT License
143 stars 74 forks source link

Deprecation issues with symfony 6.3 #78

Open phpremco opened 1 year ago

phpremco commented 1 year ago

2023-08-04T20:49:38+02:00 [info] User Deprecated: Since symfony/doctrine-bridge 6.3: Registering "App\EventSubscriber\PurifyPrePersistSubscriber" as a Doctrine subscriber is deprecated. Register it as a listener instead, using e.g. the #[AsDoctrineListener] attribute. 2023-08-04T20:49:38+02:00 [info] User Deprecated: Since symfony/doctrine-bridge 6.3: Registering "Ambta\DoctrineEncryptBundle\Subscribers\DoctrineEncryptSubscriber" as a Doctrine subscriber is deprecated. Register it as a listener instead, using e.g. the #[AsDoctrineListener] attribute.

Method Doctrine\ORM\Event\LifecycleEventArgs::getEntity() is deprecated and will be removed in Doctrine ORM 3.0. Use getObject() instead. (LifecycleEventArgs.php:44 called by DoctrineEncryptSubscriber.php:148, https://github.com/doctrine/orm/issues/9875, package doctrine/orm) in /var/www/html/vendor/doctrine/deprecations/lib/Doctrine/Deprecations/Deprecation.php on line 209

nicodemuz commented 10 months ago

I'm experiencing the same issue:

13:36:38 INFO      [php] User Deprecated: Since symfony/doctrine-bridge 6.3: Registering "Ambta\DoctrineEncryptBundle\Subscribers\DoctrineEncryptSubscriber" as a Doctrine subscriber is deprecated. Register it as a listener instead, using e.g. the #[AsDoctrineListener] or #[AsDocumentListener] attribute.
[
  "exception" => ErrorException {
    #message: "User Deprecated: Since symfony/doctrine-bridge 6.3: Registering "Ambta\DoctrineEncryptBundle\Subscribers\DoctrineEncryptSubscriber" as a Doctrine subscriber is deprecated. Register it as a listener instead, using e.g. the #[AsDoctrineListener] or #[AsDocumentListener] attribute."
    #code: 0
    #file: "./vendor/symfony/doctrine-bridge/ContainerAwareEventManager.php"
    #line: 211
    #severity: E_USER_DEPRECATED
    trace: {
      ./vendor/symfony/doctrine-bridge/ContainerAwareEventManager.php:211 { …}
      ./vendor/symfony/doctrine-bridge/ContainerAwareEventManager.php:102 { …}
      ./vendor/doctrine/orm/lib/Doctrine/ORM/Mapping/ClassMetadataFactory.php:244 { …}
      ./vendor/doctrine/doctrine-bundle/Mapping/ClassMetadataFactory.php:18 { …}
      ./vendor/doctrine/persistence/src/Persistence/Mapping/AbstractClassMetadataFactory.php:343 { …}
      ./vendor/doctrine/persistence/src/Persistence/Mapping/AbstractClassMetadataFactory.php:207 { …}
      ./vendor/doctrine/orm/lib/Doctrine/ORM/EntityManager.php:318 { …}
      ./vendor/doctrine/doctrine-bundle/Repository/LazyServiceEntityRepository.php:80 { …}
      ./vendor/doctrine/doctrine-bundle/Repository/LazyServiceEntityRepository.php:49 { …}
      ./vendor/doctrine/orm/lib/Doctrine/ORM/EntityRepository.php:223 { …}
      ...
      ./vendor/symfony/console/Command/Command.php:326 { …}
      ./vendor/symfony/console/Application.php:1096 { …}
      ./vendor/symfony/framework-bundle/Console/Application.php:126 { …}
      ./vendor/symfony/console/Application.php:324 { …}
      ./vendor/symfony/framework-bundle/Console/Application.php:80 { …}
      ./vendor/symfony/console/Application.php:175 { …}
      ./bin/console:43 { …}
    }
  }
]