ZF-7286: Zend_Validate_Int can't work if cache is not available


Assume cache_dir is not writeable - when Zend_Validate_Int tries to validate, it uses the locale it had saved in the cache. If the cache is not working because the cache_dir is not writeable for example - you get "cache_dir is not writable" when trying to validate.


0 **************/library/Zend/Cache/Backend/File.php(156): Zend_Cache::throwException('cache_dir is no...')

1 **************/library/Zend/Cache/Backend/File.php(122): Zend_Cache_Backend_File->setCacheDir('/tmp/', false)

2 **************/library/Zend/Cache.php(152): Zend_Cache_Backend_File->__construct(Array)

3 **************/library/Zend/Cache.php(93): Zend_Cache::_makeBackend('File', Array, false, false)

4 **************/library/Zend/Locale/Data.php(307): Zend_Cache::factory('Core', 'File', Array, Array)

5 **************/library/Zend/Locale/Format.php(512): Zend_Locale_Data::getList('en_US', 'symbols')

6 **************/library/Zend/Locale/Format.php(610): Zend_Locale_Format::isNumber('20', Array)

7 **************/library/Zend/Validate/Int.php(99): Zend_Locale_Format::isInteger('20', Array)

8 **************/library/Zend/Validate.php(91): Zend_Validate_Int->isValid('20')


Assigning to Thomas as he will probably look at it (if he didn't resolve this issue earlier already).

This issue duplicates ZF-7136.

It is already solved within SVN but actually blocked by the dev-team. I'm waiting for acceptance since several weeks as I was said that I am not allowed to integrate the fix to core.

As per internal discussion we decided NOT to erase the default caching. As with ZF 1.9 a migration note has been added to Zend_Locale.

Disabling the default cache is still possible with disableCache(true);