I have recently become aware of this issue and contacted Apple support.
I tried the software update, removing the keyboard prior to the update. The Ipad Pro restarted, I then connected the keyboard and the alert 'accessory is not supported by this device' appeared.
I tried the hard restart (holding the home and power buttons down until the apple logo appears) as well. I removed the keyboard before beginning the hard restart. I saw the alert 'accessory is not supported by this device' again.
I've cleaned the connections on both the Ipad Pro and keyboard, I've wiped the groove clear of any debris to no avail.
I've spent 1 hour and 30 minutes on the phone with apple support so far and I get the impression that this is my fault for buying an apple product to work with an apple product.
The first solutions provided were to take it to a Best Buy (Apple stores are closed) or mail it in for service/repair/replacement.
My children need this to work--it is supposed to be their 'computer' to continue learning from home. That's how Apple advertised and marketed this device and the accessories. Without this device working properly my children cannot type their answers and complete their school work. The last day I could pick up a tablet from the school to use at home was three weeks ago, our schools are now closed for the year.
I cannot believe that Apple wouldn't be more helpful to educators and those of us who are trying to maintain what little sense of normalcy (read; educating from home) we have left during this time.
I am using this experience in the same way people are recognizing companies that have either supported or abandoned their employees during this crazy time.
I wanted to add that 'Destiny' and 'Lauren', the two people from Apple support did what they could to help. The operators are limited by Apple and they are in no way guilty of anything other than trying to help (although without asking the questions your level of help will vary).
Update: Apple support asked me to send the following to the 'engineering dept'; the diagnostics, screen recordings of the alert appearing on the screen, screenshots of the alert on the screen, and a screenshot of settings>keyboard screen. Apple will call me on 4.10.2020 with a response.