Fix pydev import error. Fixes #591