a simple script not working in blender 2.8
The problem was not with the naming conventions (or at least, that wasn't the only problem, I don't know if Blender does enforce this). I also had 'TABERROR' object has no attribute 'msg' and I didn't have any classes in my script.

I finally found out what the problem was. The file failed to parse (hence no line number information) because there was an invisible error in the indentation. In particular, some lines were indented with tabs, others with spaces. In my case this was caused by me using tabs for indentation in my own editor, then editing the script in Blender's text editor, which automatically inserts spaces instead.

Opening it back up in my text editor and making all indentation consistent fixed the problem.