Hi,
I don't think that changing the version of PHP from 8.2 to 8.3 will prevent this error.
It's probably just a coincidence that the version change "fixed" the problem.
When you get an error like that, the first thing to do is to activate the "debug" setting of the Joomla configuration page and then reproduce the issue. You'll then get the complete error message, which will allow us to understand what's going on and provide a solution. With the abbreviated error message, we don't have enough information to know what's going on and thus we can't provide a solution.