Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Non-existent service after fresh installation on branch 5.0.x #830

Closed
michaelthieulin opened this issue Dec 22, 2023 · 7 comments · Fixed by #831
Closed

Non-existent service after fresh installation on branch 5.0.x #830

michaelthieulin opened this issue Dec 22, 2023 · 7 comments · Fixed by #831
Labels
Milestone

Comments

@michaelthieulin
Copy link

Environment :

  • Symfony 7.0
  • PHP 8.3 with mongodb extension

When I install a fresh version of Symfony with the symfony cli :

symfony new test --webapp --version="stable"

Then, i add the DoctrineMongoDBBundle :

composer require doctrine/mongodb-odm-bundle:5.0.x-dev

Then I answer yes for the recipe execution.

I have the following error while the execution of the @auto-scripts part of composer.json, more precisely in the cache:clear command :

The service "doctrine_mongodb.odm.command.load_data_fixtures" has a dependency on a non-existent service "doctrine_mongodb.odm.symfony.fixtures.loader".

I managed to fix this by installing doctrine/data-fixtures but I don't want to have this package in prod environment.

After accessing the page http://127.0.0.1:8000/ after launching symfony serve in the test directory, I have the following error :

The profiler template "@DoctrineMongoDB/Collector/mongodb.html.twig" for data collector "mongodb" does not exist.

Thanks and mainly thanks for the hard work.

@malarzm malarzm added this to the 5.0.0 milestone Dec 22, 2023
@malarzm malarzm added the bug label Dec 22, 2023
@GromNaN
Copy link
Member

GromNaN commented Dec 22, 2023

I'm on it. Thanks for the report.

@MatTheCat
Copy link

Just hit this one; $container->removeDefinition(LoadDataFixturesDoctrineODMCommand::class); should be $container->removeDefinition('doctrine_mongodb.odm.command.load_data_fixtures'); in the DoctrineMongoDBExtension.

@franmomu
Copy link
Contributor

That was my fault in #810 that I added ids based on the best practices, but forgot to search usages.

@MatTheCat
Copy link

@michaelthieulin maybe you should create another issue regarding the profiler template?

@michaelthieulin
Copy link
Author

Thanks for the ultra speed fix 🤣
I open another issue for the template.

@GromNaN
Copy link
Member

GromNaN commented Dec 22, 2023

I'm looking at the template issue.

@GromNaN
Copy link
Member

GromNaN commented Dec 22, 2023

Template issue fix: #833

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

5 participants