10000 [Cache] Cannot redeclare class Acme in /path/to/Acme.php · Issue #25484 · symfony/symfony · GitHub
[go: up one dir, main page]

Skip to content
[Cache] Cannot redeclare class Acme in /path/to/Acme.php #25484
Closed
@althaus

Description

@althaus
Q A
Bug report? yes
Feature request? no
BC Break report? no
RFC? no
Symfony version 3.4.1
PHP version 5.6.x

After upgrading to Symfony 3.4.1 I'm encountering strange caching issues.

In dev I get "Cannot redeclare class EventSubscriberInterface" with a fresh cache after the first successfull page load. In that case the first broken call is the web profiler on that exact page. Reloading the page directly runs into the FatalErrorException. I got it twice directly after executing a doctine:migration:foo command and once after switching branches or something like that.

In prod I get (on my dev and another totally different machine) a "PHP Fatal error: Cannot redeclare class appProdProjectContainer in /var/www/conti.ido.software/git/devel/var/cache/prod/appProdProjectContainer.php on line 7519" on warming up the cache.

In dev I could fix it by randomly removing cache, clearing cache and writing dump("foo") into the EventSubscriberInterface file in no particular order. I found #21520 which sounds related.

It's driving me nuts.

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

      0