manticoresoftware / manticoresearch-php

Official PHP client for Manticore Search
MIT License
167 stars 32 forks source link

Drop support for older versions of php #143

Closed aivchen closed 5 months ago

aivchen commented 12 months ago

PHP 7.1 - 7.4 are not supported by php core developers. PHP 8.0 will stop to be supported in November 2023.

I suggest to drop support for all < 8.1 php versions in next major release. It would allow to use strict types for variables, parameters, use readonly properties etc.

What do you think?

sanikolaev commented 11 months ago

Thank you for bringing up this idea!

According to https://stitcher.io/blog/php-version-stats-january-2023, at the beginning of the year, approximately a quarter of PHP users were using PHP 7.4, and only 23% of the top 1,000 popular packages required a version >= 8.

It would be beneficial to find updated statistics. However, if the numbers haven't changed significantly, it seems premature to drop support.

aivchen commented 11 months ago

https://packagist.org/php-statistics

For September 2023: image

I think we can drop support for php < 7.4. What do you think?

sanikolaev commented 11 months ago

According to https://github.com/manticoresoftware/manticoresearch-php#requirements , the latest releases of the client already support PHP >= 7.4.

aivchen commented 11 months ago

Yes, but in composer.json the requirement is php >= 7.1.

sanikolaev commented 11 months ago

Yes, but in composer.json the requirement is php >= 7.1.

@Nick-S-2018 is this a mistake?

aivchen commented 11 months ago

Technically, this is a mistake in the documentation, because the code is more important than the documentation. Currently, all versions of manticoresearch-php can be used in any project running on php >=7.1.

Nick-S-2018 commented 5 months ago

Done in https://github.com/manticoresoftware/manticoresearch-php/commit/7ec10d479d0c9980cc14379c34d26de13a4a559b