move sys import to top

This is to avoid that mocked import machinery breaks importing.
v0.5.4