shaarli / Shaarli

The personal, minimalist, super-fast, database free, bookmarking service - community repo
https://shaarli.readthedocs.io/
Other
3.41k stars 287 forks source link

Tests compatibily with PHP 5.3 #250

Closed ArthurHoaro closed 9 years ago

ArthurHoaro commented 9 years ago

I mentionned in #218 that tests are not compatible with PHP 5.3. I thought it didn't matter because we run test in dev environment. However, if we wan't to keep 5.3 compatibility for Shaarli, and avoid issue like #241, it would be better if we could test it in PHP 5.3.

We could also drop PHP 5.3 compatibility since it's an old and apparently not maintained version.

nodiscc commented 9 years ago

We could also drop PHP 5.3 compatibility

Yes. PHP 5.3 also has a lot of unfixed security vulnerabilities: www.cvedetails.com/version-list/74/128/3/PHP-PHP.html?order=1&trc=265. I'll probably merge https://github.com/shaarli/Shaarli/pull/249 as this is a simple fix, but PHP 5.3 should not be a requirement.

Debian has PHP 5.6 in stable and 5.4 in oldstable (https://packages.debian.org/search?keywords=php5)! Should we bump the requirements in the README to PHP 5.4/5.5 ?

virtualtam commented 9 years ago

+1 for having 5.4 as a minimum requirement

ArthurHoaro commented 9 years ago

Should we update checkphpversion() to display an error if PHP version is < 5.4?

virtualtam commented 9 years ago

I'd say "yes for now", and take some time to toy with phpenv to see how much work would be needed to keep 5.3 compatibility (did I mention it's a very old version? :p)

virtualtam commented 9 years ago

For now, the sole constraint seems to have to declare arrays by explicitely using array() instead of []. Before merging #271, I'd like to know if anyone has encountered other issues with 5.3.x versions of PHP...

ArthurHoaro commented 9 years ago

PR merged.