Details
-
Bug
-
Resolution: Fixed
-
Low
-
Customer request, 5.1, 5.2, 2014.01, 5.3-dev
Description
I get exceptions in dev and prod environments when trying to generate an alias for a image not existing in the disk.
Easy to reproduce if you have an updated version of your database (you have dumped your prod db to your dev environment) and you don't have all the files in the dev environment
Exception reads like this (prod.log)
[2014-01-29 16:42:31] request.CRITICAL: Uncaught PHP Exception Twig_Error_Runtime: "An exception has been thrown during the rendering of a template ("Invalid variation 'line' for image") in "[ABUNDLE]:fields:ezimage_simple.html.twig"." at [...]/ezpublish/cache/prod/classes.php line 4465 {"exception":"[object] (Twig_Error_Runtime: An exception has been thrown during the rendering of a template (\"Invalid variation 'line' for image\") in \"[ABUNDLE]:fields:ezimage_simple.html.twig\". at /[...]/ezpublish/cache/prod/classes.php:4465, eZ\\Publish\\API\\Repository\\Exceptions\\InvalidVariationException: Invalid variation 'line' for image at /[...]/sb5/sillonbol/vendor/ezsystems/ezpublish-kernel/eZ/Publish/Core/MVC/Legacy/Image/AliasGenerator.php:93)"} []
For creating the alias, legacy function is called. It seems that function doesn't return an array when the original file is not present and show the exception is thrown.
Attachments
Issue Links
- relates to
-
EZP-21238 Error when an image alias isn't found
- Closed
-
EZP-20502 avoid Symfony exception when file is missing for ezimage attribute
- Closed
-
EZP-22476 DemoBundle stack thrown if image alias not found.
- Closed
-
EZP-22508 backport from issue EZP-22272 is needed
- Closed
-
EZP-23287 empty Image FieldType triggers twig_error_runtime
- Closed