On Mon, 09 May 2016 at 19:34:37 +0200, Markus Koschany wrote:
> However when I edit test.setup and edit
> 
> img_allowed_formats: 'png, jpeg'
> 
> because I want to be even more restrictive I get the following error
> message:
> 
> Error: Can't use string ("png, jpeg") as an ARRAY ref while "strict
> refs" in use at /usr/share/perl5/IkiWiki/Plugin/img.pm line 39

It's meant to be a YAML list, you've set it to a string. The correct
syntax is, for example, any of

    img_allowed_formats: [png, jpeg]

    img_allowed_formats: ["PNG", "JPEG"]

    img_allowed_formats:
    - png
    - jpeg

<http://ikiwiki.info/ikiwiki/directive/img/> describes one form of correct
syntax. I didn't include documentation updates in the wheezy update to keep it
minimal.

> This used to work with the current version in Wheezy. Is this
> intentional or a regression?

There was no option of that name in the current version in Wheezy. All
versions prior to last Friday effectively had the same behaviour as if you
used

    img_allowed_formats: [everything]

in the updated version.

When you tried it, it "worked" in the sense that it was accepted and
ignored like any other unimplemented setting, exactly as though you
had written

    permissive format is permissive: 'yes, this'

in your setup file :-)

    S

Reply via email to