yiisoft / yii

Yii PHP Framework 1.1.x
http://www.yiiframework.com
BSD 3-Clause "New" or "Revised" License
4.84k stars 2.28k forks source link

PHP version support is not explicit enough in docs #4487

Closed sparkcodeuk closed 2 years ago

sparkcodeuk commented 2 years ago

What steps will reproduce the problem?

N/A

What is the expected result?

N/A

What do you get instead?

N/A

Additional info

I think it would be best to list the exact minor versions of PHP versions that the Yii 1 framework supports (as a range).

The current README.md states:

"The minimum requirement by Yii is that your Web server supports PHP 5.1.0 or above. Yii has been tested with Apache HTTP server on Windows and Linux operating systems."

Which strictly is not true as the current release does not officially support PHP 8.1.

I finally found some reassurance here about what is/isn't supported: https://github.com/yiisoft/yii/blob/859b2f2e1d22345a9475a809a24cfecd24ad50a5/CHANGELOG

"- Enh #4386: Added support for PHP 8.1 (marcovtwout, JonathanArgentao, ivany4)"

But it would be better if this was made clearer in the README.md (and not having to assert it from the CHANGELOG).

So it looks like:-

If this could be made official under a separate heading, e.g., "SUPPORTED PHP VERSIONS" in the README.md

And for the 1.1.26 release the text would state something to the effect of "The Yii 1 framework officially supports all PHP versions from 5.1 up to and including 8.1"

Many thanks.

Q A
Yii version 1.1.25
PHP version N/A
Operating system N/A
marcovtwout commented 2 years ago

@sparkcodeuk We could detail PHP versions per release, but I'm not sure that information would be any more true. Even after declaring support issues are found and fixed in new minor versions.

I'm fine with declaring the current maximum supported version in the README, would that help sufficiently? (currently 8.0, soon 8.1)

rob006 commented 2 years ago

I would rather focus on releasing more often. Most of PHP 8.1 issues was fixed half a year ago.

sparkcodeuk commented 2 years ago

@sparkcodeuk We could detail PHP versions per release, but I'm not sure that information would be any more true. Even after declaring support issues are found and fixed in new minor versions.

I'm fine with declaring the current maximum supported version in the README, would that help sufficiently? (currently 8.0, soon 8.1)

Thanks for the reply @marcovtwout, yes I think a simple range as you say would work fine.

My main concern was not knowing whether I was going to find some subtle backwards compatibility 8.1 issues in production (i.e., should have "played it safe" with PHP 8.0).

So for instance, we should all assume the upcoming PHP 8.2.0 RCs are not officially supported by any releases until we see it included in the published PHP versions range in the README.

I would rather focus on releasing more often. Most of PHP 8.1 issues was fixed half a year ago.

@rob006 unless you're either active in Yii1 framework development or visit the issues section here on a regular basis, I'm not sure how you would ever ascertain how well a particular PHP version is supported unless it's explicitly stated in the docs somewhere, something which is common/user-friendly and trivial to implement.


@marcovtwout feel free to close this as/when you like.

marcovtwout commented 2 years ago

@sparkcodeuk If you want to play it safe you should use the latest stable and 8.0. Even after the upcoming release with 8.1 support, it is likely new 8.1 issues will still pop up.

marcovtwout commented 2 years ago

Fixed by https://github.com/yiisoft/yii/commit/8b35ee9c19b4f2540ee8e99e04ffaff09921ce03