symfony / orm-pack

A Symfony Pack for Doctrine ORM
MIT License
1.82k stars 18 forks source link

Missing DoctrineTransportFactory (symfony/messenger) #38

Closed mvhirsch closed 1 year ago

mvhirsch commented 1 year ago

I think this package needs symfony/doctrine-messenger since I can not use symfony/symfony ^5.4 and symfony/orm-pack ^2.2 together without that package. I'm not using Symfony Flex.

Running bin/console with just give me:

The autoloader expected class "Symfony\Component\Messenger\Transport\Doctrine\DoctrineTransportFactory" to be defined in file "/var/www/html/vendor/composer/../symfony/symfony/src/Symfony/Component/Messenger/Transport/Doctrine/DoctrineTransportFactory.php". The file was found but the class was not in it, the class name or namespace probably has a typo.

Well, true. This class is deprecated:

// Symfony\Component\Messenger\Transport\Doctrine\DoctrineTransportFactory.php

if (false) {
    /**
     * @deprecated since Symfony 5.1, to be removed in 6.0. Use symfony/doctrine-messenger instead.
     */
    class DoctrineTransportFactory
    {
    }
}
$> grep symfony\/ composer.json 
        "symfony/monolog-bundle": "^3.8",
        "symfony/orm-pack": "^2.2",
        "symfony/symfony": "^5.4"

After requiring symfony/doctrine-messanger, the autoloading/-wiring works fine.

nicolas-grekas commented 1 year ago

Using symfony/symfony directly is not supported.