I am running Symfony 2.0.6, and I get the following error:

InvalidArgumentException: There is no extension able to load the configuration for "knp_menu" (in /home/www/Symfony/app/config/config.yml). Looked for namespace "knp_menu"

It works in DEV, but not in PROD enviroment.

有帮助吗?

解决方案

The error message means that you got an entry "knp_menu" in your config.yml which is not used by any extension.

It's either a caching problem (you introduced the extension, e.g. a bundle, and then not cleared the prod cache), or you load a specific bundle only within the dev environment (as the profiler in a default symfony2 app).

Try clearing the cache using php app/console clear:cache --env=prod --no-debug. If the problem exists anyhow, find out which bundle uses knp_menu and either delete the configuration or enable the bundle.

许可以下: CC-BY-SA归因
不隶属于 StackOverflow
scroll top