Hari if MySQL is not running how flarum is working (confused)
Check the timestamp of the error. It likely doesn't match with the time of your oauth tests, and probably happened sometime before or after. At that exact time, you or a visitor must have attempted to access the website, and at that time the webserver and PHP were working, but the database was offline. Maybe this coincides with a server restart, or an automated server snapshot or backup.
If you never saw the 500 error page for that error yourself, it was likely a visitor or a bot that tried to visit your website and saw an error page. If there's a single entry with that error in the log file, it likely was a very short issue. If there are multiple logs, you could try to plot from when and for how long MySQL was down, and check what was happening on the server at that time.