Skip to content

Class name conflict with Symfony Bridge proxy manager and Ocramius ProxyManager #33364

Closed
@crmpicco

Description

@crmpicco

Symfony version(s) affected: 3.4.31

Description
I am experiencing a warning when running composer dump-autoload --optimize in my application and it is happening because of my apparent use of the proxy manager along with the Symfony bridge.

How to reproduce

$ composer dump-autoload --optimize
Generating optimized autoload files

Warning: Ambiguous class resolution, "ProxyManager\Generator\Util\ProxiedMethodReturnExpression" was found in both "/private/var/www/crmpicco/symfony/vendor/ocramius/proxy-manager/src/ProxyManager/Generator/Util/ProxiedMethodReturnExpression.php" and "/private/var/www/crmpicco/symfony/vendor/symfony/symfony/src/Symfony/Bridge/ProxyManager/Legacy/ProxiedMethodReturnExpression.php", the first will be used.

Generated optimized autoload files containing 8939 classes 

I am using Proxy-Manager 2.2.3:

$ composer show -i | grep proxy
You are using the deprecated option "installed". Only installed packages are shown by default now. The --all option can be used to show all packages.
ocramius/proxy-manager               2.2.3                 A library providing utilities to generate, instantiate and generally operate with Object Proxies

Additional context
I reported this on Ocramius' Github account, however he suggested it is a Symfony issue and pointed me in this direction. Ocramius/ProxyManager#489 (comment)

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions