Correct handling of static method completions + completion more resistant

- Fixes Issue 532:	Unhandled event loop exception or how to break the codecompletion engine in current repl session