chillerlan / php-qrcode

A PHP QR Code generator and reader with a user-friendly API.
https://smiley.codes/qrcode/
Apache License 2.0
2k stars 297 forks source link

[DOCS] PHP 8.1 as minimum requirement #257

Closed jbostoen closed 6 months ago

jbostoen commented 6 months ago

Describe the documentation issue or addition It seems when using composer to install the latest php-qrcode, it actually uses the php-settings-container which now requires PHP 8.1.

Proposed change/addition (if applicable)

The documentation stated the 5.x release was still compatible with PHP 7.4. However, this seems not to be the case (by default) anymore.

Additional context

https://github.com/chillerlan/php-qrcode/releases/tag/4.4.0 explicitly mentions the 5.x branch should be compatible with PHP 7.4.

codemasher commented 6 months ago

Hi, thanks for the report! The v5.x branch uses a version switch for this dependency as its API is fully compatible, so if you're installing php-qrcode on PHP 8.1+ it will install the newer dependency.

https://github.com/chillerlan/php-qrcode/blob/da5bdb82c8755f54de112b271b402aaa8df53269/composer.json#L45

And so does v4.4.x https://github.com/chillerlan/php-qrcode/blob/52889cd7ab1b78e6a345edafe24aa74bc5becc08/composer.json#L29

jbostoen commented 6 months ago

Thanks for that info! :)

I'll need to check it out. My personal development instance is PHP 8.1; but it was deployed on PHP 7.4 with a simple file copy. I was hoping to avoid the need to run composer again on the production environment.

codemasher commented 6 months ago

The unit test would yell at me if it wasn't compatible with PHP 7.4 :)

https://github.com/chillerlan/php-qrcode/actions?query=branch%3Av4.3.x

codemasher commented 6 months ago

I'm going to close this here. Feel free to hop over to the discussions section if you have further questions.