Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Suppress MySQLi errors so that MythWeb works with PHP 8.1.0. #84

Merged
merged 1 commit into from
Jul 20, 2022

Conversation

mymatenige
Copy link
Contributor

Resolves issue #83.

@jfabernathy
Copy link

I have also tested these patches and they worked on Debian Testing (Bookworm) which uses php 8.1

@billmeek billmeek merged commit 92f0f9b into MythTV:master Jul 20, 2022
@stuarta
Copy link
Member

stuarta commented Jul 22, 2022

I don't believe blindly silencing the errors is the correct course of action

@paul-h
Copy link

paul-h commented Jul 22, 2022

It's not really an error it's more a change in the default behaviour in PHP 8.1 or later. Older version of PHP allowed the query to look for the MythMusic table even if the table didn't exist. Newer PHP version now by default throw an exception if the table does not exist. All the patch does is tell PHP to revert to the old behaviour. All MythWeb wants to know is has the user used MythMusic at all. If they have the the relevant music tables must have been created so it can show the Music options in the MythWeb UI.

Seems a quick and simple fix to me. If MythWeb was still under active development then maybe we could improve it but since it has worked fine the last 200 years give or take :) like it is until the PHP change I don't see any point in that.

@mymatenige
Copy link
Contributor Author

Agreed; the pull request just makes MythWeb behave the same way with PHP 8.1 as it did with 8.0 and previous versions. The MySQL issues have always been there, it's just that in PHP 8.1 they became exceptions rather than errors; https://php.watch/versions/8.1/mysqli-error-mode.

@mymatenige mymatenige deleted the php-8.1 branch July 23, 2022 06:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

5 participants