When deleting a course that contains a Colze-type question, a "Question does not exist" error occurs and the course is not completely deleted from the database. I am able to reproduce this bug by simply creating a course, adding a Cloze-type question to it (using the example in Moodle Docs) and then trying to delete it. After the error occurs, I retry deleting the course and it works. With courses with many Cloze-type questions I have to retry a few times before the course deletion is completed.
Tested using the latest 1.9 build (20080409).