I fixed my problem, so I’ll share the solution just in case it helps anyone.
I enabled gnome-screensaver debugging by doing this:
pkill gnome-screensaver
gnome-screensaver --no-deamon --debug 2>&1 | tee ~/g-ss.log
Then in the log file, I noticed it was saying Locking disabled by the administrator whenever I tried to lock.
I found these two settings:
gsettings get org.gnome.desktop.screensaver lock-enabled
gsettings get org.gnome.desktop.lockdown disable-lock-screen
Both of these were true, but I reckon the second one should be false, so I changed it with set instead of get.
Now everything works fine - none of the other fixes mattered in my situation.
I have no idea why the upgrade would’ve changed that variable to disable the lock screen, but hey-ho, fixed now!