Simple Machines Community Forum

SMF Support => SMF 2.0.x Support => Topic started by: mrsfalcon on February 15, 2021, 02:02:25 PM

Title: Problems after upgrading to php 7.4
Post by: mrsfalcon on February 15, 2021, 02:02:25 PM
I'm experiencing a number of problems after upgrading to php 7.4. Users are logging in and appearing as other users. SMF has identified errors in the number of replies, but when I try to fix them, I get the error "The database value you're trying to insert does not exist: num_replies".

My error logs are also filling up with this error:
Trying to access array offset on value of type nullApply Filter: Only show the errors from this File: *path*/forum/Sources/Load.php
Line: 168

I am running SMF version SMF 2.0.18. Any suggestions?
Title: Re: Problems after upgrading to php 7.4
Post by: Aleksi "Lex" Kilpinen on February 15, 2021, 03:04:17 PM
Those would sound like multiple issues that actually shouldn't really be related to each other, or the PHP version.
Quote from: mrsfalcon on February 15, 2021, 02:02:25 PM
Users are logging in and appearing as other users.
Appearing how? Are they seeing wrong user information, or can they actually post as a different user?

Quote from: mrsfalcon on February 15, 2021, 02:02:25 PM
SMF has identified errors in the number of replies, but when I try to fix them, I get the error "The database value you're trying to insert does not exist: num_replies".
Can you check your error log, and see if there is a "more complete" error related to this happening?

Quote from: mrsfalcon on February 15, 2021, 02:02:25 PM
Trying to access array offset on value of type nullApply Filter: Only show the errors from this File: *path*/forum/Sources/Load.php
Line: 168
Is that the complete error? What is actually on that line, or around it - Could you maybe copy lines 165-175 here between code tags?
Title: Re: Problems after upgrading to php 7.4
Post by: mrsfalcon on February 15, 2021, 04:38:31 PM
I wasn't able to make much traction, even after running repair_settings, so I created a new directory, downloaded a new copy of the latest SMF, and pointed it at the old database. This worked very well. I did a bunch of things in a very short period of time: moved to a new server, upgraded php, and upgraded smf, and I suspect that I had a file corrupt somewhere along the way.  Lex, I did try changing load.php as suggested on this forum, but that didn't help.

Bad part: unhappy forum members for the last day. Great part: Fresh clean install! I'm having one last problem but it isn't related to this, so I'll open a new thread if I can't figure it out.

Thanks and this can be considered closed.