Netbeans - tabs are not typed in empty lines

Make sure you have the latest JDK installed and used by Netbeans.
Currently 17.0.1 (01.2022).

I was using Netbeans 12.6 with jdk 1.8.0_261. When pressing TAB on an empty line nothing happened but in the bottom right corner you can see a notification that a unexpected MethodNotFound Exception is thrown. Installing JDK 17.0.1 fixed it. Make sure your IDE actually uses the new JDK by going to
Tools -> Java Platforms and the JDK 17 is the default one.