Exercise / HTMLPurifierBundle

HTML Purifier is a standards-compliant HTML filter library written in PHP.
http://htmlpurifier.org/
Other
275 stars 56 forks source link

Cache directory is not being created by the bundle, v2.0 #54

Closed alister closed 6 years ago

alister commented 6 years ago

The line <tag name="kernel.cache_warmer" /> has been removed from the file ./Resources/config/html_purifier.xml, and so the cache warmer is not being run on the framework startup.

Further, when the cache is being built, there are issues with key="$paths" unless it is removed OR a key="$htmlPurifier" is added on the next line.

Both of these for the block <service id="exercise_html_purifier.cache_warmer.serializer" ..., work.

<argument>%exercise_html_purifier.cache_warmer.serializer.paths%</argument>
<argument type="service" id="HTMLPurifier" />
<tag name="kernel.cache_warmer" />

OR

<argument key="$paths">%exercise_html_purifier.cache_warmer.serializer.paths%</argument>
<argument key="$htmlPurifier" type="service" id="HTMLPurifier" />
<tag name="kernel.cache_warmer" />
asentner commented 6 years ago

Thanks for the fix! Looks like I'll be using a forked version for now until this gets merged in.

asentner commented 6 years ago

Thank you @spolischook!

spolischook commented 6 years ago

np, just remember that test that you write (should write) with your PR, can decrease the time for review and increase durability of your changes.

jrjohnson commented 6 years ago

Thanks, the fix in V2.0.0-BETA2 works. Just a note to anyone else tracking this ticket - I had to upgrade from 2.0.0 to 2.0.0-BEAT2 manually since composer didn't see the BETA tag as a stable update from 2.0.0 and a regular composer update wont cut it.

spolischook commented 6 years ago

@jrjohnson thanks for the note. I've update the version https://github.com/Exercise/HTMLPurifierBundle/releases/tag/V2.0.1

jrjohnson commented 6 years ago

@spolischook thanks, but it still doesn't show up as the latest on https://packagist.org/packages/exercise/htmlpurifier-bundle