I had this issue today with macOS 15.1 Beta 7, I've never ran into this ever until today. I seen another post elsewhere before I seen this and what worked for me was opening the Mac App Store, in the menu bar > Store > Sign out, and then back to system settings and trying again and it worked for me.
I had seen posts were people where putting their Mac into DFU mode and using configurator to get around the error which puzzled me when everything else worked so for anyone else that runs into this they can now try the method above or the Mac App Store method.
😄