fixes #120 and #121
fixed docstring for `atexit.register`
removed unused import
Merge pull request #227 from Gallopsled/atexit-issue-120-and-121

fixes #120 and #121