kriswallsmith / assetic

Asset Management for PHP
MIT License
3.75k stars 555 forks source link

PHP Fatal error AsseticFilterFunction may not inherit from final class (Twig_SimpleFunction) #835

Open gondo opened 7 years ago

gondo commented 7 years ago

after running composer update on my project and after running app/console --env=test cache:clear it failed with this error:

PHP Fatal error:  Class Assetic\Extension\Twig\AsseticFilterFunction may not inherit from final class (Twig_SimpleFunction) in ~/project/vendor/kriswallsmith/assetic/src/Assetic/Extension/Twig/AsseticFilterFunction.php on line 24
gondo commented 7 years ago

only works for "twig/twig": "<2.0"

stof commented 7 years ago

arf, I forgot that we add a class extending it here, and that Twig made them final.

the work is almost done to get rid of it. I will work on it this evening. In the meantime, stick to Twig 1.x

eDavidT commented 7 years ago

Any update on when this will get fixed?

smcjones commented 7 years ago

Symfony 3.3 now triggers an error for this.

The "Twig_TokenParser_Include" class is considered final. It may change without further notice as of its next major version. You should not extend it from "Twig_TokenParser_Embed"

OnekO commented 7 years ago

This can be easily fix with this patch: https://github.com/kriswallsmith/assetic/pull/854

hvt commented 7 years ago

Hey @stof, do you have an update on this?