The reverse engineering command requires existing entities #5702

Closed
opened 2026-01-22 15:15:00 +01:00 by admin · 2 comments
Owner

Originally created by @Kwadz on GitHub (Sep 16, 2017).

Originally assigned to: @Ocramius on GitHub.

The documentation sates that the first step is to create the metadata files:

screen shot 2017-09-16 at 12 55 10

This suggests we can start from scratch, without any existing entities in AppBundle/Entity. However with a fresh install of a symfony_demo project, created with symfony demo, when we execute the following command:

php bin/console doctrine:mapping:import --force AppBundle xml

we get:

Fatal error: Symfony\Component\Debug\DebugClassLoader::loadClass(): Failed opening required 'xxx/symfony_demo/vendor/composer/../../src/AppBundle/Entity/Post.php' (include_path='.:') in xxx/symfony_demo/vendor/symfony/symfony/src/Symfony/Component/Debug/DebugClassLoader.php on line 144
Originally created by @Kwadz on GitHub (Sep 16, 2017). Originally assigned to: @Ocramius on GitHub. The [documentation][1] sates that the first step is to create the metadata files: > <img width="718" alt="screen shot 2017-09-16 at 12 55 10" src="https://user-images.githubusercontent.com/1472599/30511719-71bee4e6-9adf-11e7-98fc-2ec68db385bd.png"> This suggests we can start from scratch, without any existing entities in `AppBundle/Entity`. However with a fresh install of a symfony_demo project, created with `symfony demo`, when we execute the following command: `php bin/console doctrine:mapping:import --force AppBundle xml` we get: ``` Fatal error: Symfony\Component\Debug\DebugClassLoader::loadClass(): Failed opening required 'xxx/symfony_demo/vendor/composer/../../src/AppBundle/Entity/Post.php' (include_path='.:') in xxx/symfony_demo/vendor/symfony/symfony/src/Symfony/Component/Debug/DebugClassLoader.php on line 144 ``` [1]: https://symfony.com/doc/current/doctrine/reverse_engineering.html
admin added the BugIncomplete labels 2026-01-22 15:15:00 +01:00
admin closed this issue 2026-01-22 15:15:02 +01:00
Author
Owner

@Ocramius commented on GitHub (Sep 16, 2017):

Please reproduce this with the plain ORM: with Symfony in the mix, we really can't help you. The specific exception even shows symfony specific details.

Closing here, please reopen once isolated the bug.

@Ocramius commented on GitHub (Sep 16, 2017): Please reproduce this with the plain ORM: with Symfony in the mix, we really can't help you. The specific exception even shows symfony specific details. Closing here, please reopen once isolated the bug.
Author
Owner

@Kwadz commented on GitHub (Sep 16, 2017):

Sorry, wrong place... This is related to DoctrineBundle.

@Kwadz commented on GitHub (Sep 16, 2017): Sorry, wrong place... This is related to [DoctrineBundle](https://github.com/doctrine/DoctrineBundle).
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: doctrine/archived-orm#5702