Conflicts with Symfony2 AsseticBundle and the 'non existing routes'

php, symfony

Solution

I had same problem. In my case clearing app/cache and app/logs solved the issue.

Problem

Assetic doesn't work very wells with this tag: ``` {% stylesheets output='/style/app.css' '@VendorBundle/Resources/style/main.css' %} <link rel="stylesheet" href="{{ asset_url }}"/> {% endstylesheets %} ``` If I use it, it's like Assetic doesn't know what to do with this. In config_dev `use_controller` is true. I can't find what I'm doing wrong. I just get this: An exception has been thrown during the rendering of a template ("Unable to generate a URL for the named route "_assetic_aca6c7a_0" as such route does not exist.") in "VendorBundle:Section:template.html.twig". Maybe some cache issue? I don't know what I can try...

Original source