problema al activar extensiones text y debug de tiwg

74 views
Skip to first unread message

Reumo

unread,
Apr 24, 2014, 5:19:09 AM4/24/14
to symfony...@googlegroups.com
pongo eso en el config.yml por activar las extensiones text y degub de twig

services:
    twig.extension.text:
    class: Twig_Extensions_Extension_Text
    tags:
      - { name: twig.extension }
      
    twig.extension.debug:
    class: Twig_Extensions_Extension_Debug
    tags:
       - { name: twig.extension }


y me pasa el siguiente error

RuntimeException: The definition for "twig.extension.text" has no class. If you intend to inject this service dynamically at runtime, please mark it as synthetic=true. If this is an abstract definition solely used by child definitions, please add abstract=true, otherwise specify a class to get rid of this error.


Si alguien me puede ayudar

Salu2

Reumo

daniel....@freelancemadrid.es

unread,
Apr 24, 2014, 6:45:30 AM4/24/14
to symfony...@googlegroups.com
2014-04-24 11:19 GMT+02:00 Reumo <remo.ca...@gmail.com>:

RuntimeException: The definition for "twig.extension.text" has no class. If you intend to inject this service dynamically at runtime, please mark it as synthetic=true. If this is an abstract definition solely used by child definitions, please add abstract=true, otherwise specify a class to get rid of this error.


Parece que está bien ... pero puedes ...

1.-  Comprobar que la tabulación es correcta en el yml y no tiene "tabs"
2.-  Limpiar la cache?


Saludos!
--
-------------------------------------------------------------------------------------
Daniel González Cerviño
Developer http://desarrolla2.com
Tel (+34) 653 96 50 48
Mail daniel....@freelancemadrid.es
Twiter: http://twitter.com/desarrolla2
Linkedin: http://www.linkedin.com/in/desarrolla2
Github: https://github.com/desarrolla2
-------------------------------------------------------------------------------------

Reumo

unread,
Apr 24, 2014, 9:03:12 AM4/24/14
to symfony...@googlegroups.com
no tengo tabulaciones y cuando limpio la cache me saca el mismo error

Reumo

unread,
Apr 24, 2014, 9:10:00 AM4/24/14
to symfony...@googlegroups.com
Resuelto,  tenia mal puesto el nivel del class y del tags

asi funciona:
Reply all
Reply to author
Forward
0 new messages