Ok, this may not be a high priority bug, but after 10 months, the bug is still there?
FWIW, I also use tsclient (so as client, to connect to a windows machine) and it may be related to the mouse keys switching on, but its hard to find a pattern, and it occurs even when tsclient is not running. But without having run tsclient during a session, I have not yet encountered it afaict.
Once you know what is happening, and you know shift+numlock disables it again, it is no drama. But most users will not read this and think ubuntu can not even drive a keyboard without errors. In that light, its a bit disappointing this still isn't fixed. If nothing else, I think a notification should be given when mousekeys are turned on (with or without this bug), so at least people might realize whats going on. Just a little balloon stating "mouse keys turned on. Press shift+numlock to turn off again".