Same thing with me since Beta 3 on an M1 mini. Thought it was first because of using ARD to run Parallels and was having tab/spacebar issues when doing that with everything in Parallels. Now at beta 5 arm and spacebar randomly not working. Will work with Notes, and Mi, but won't work in Excel or various screens in Parallels, at the same time In Parallels the space bar pops up the configuration menu. in beta 5 the spacebar is completely unusable for quick look, it causes a blue box to appear around the finder window. So, for me, Quick Look is totally unoperable.
Thought it was my KVM, but bypassing that didn't solve anything. Thought it was my Kensington keyboard and was due to my option & command keys needing to be remapped, but that wasn't it. Put back on an plain old ordinary USB Apple keyboard, but the same things happen with it too. Only thing I can do is to do when it happens is to do shift-spacebar to get spaces going.