try to fix deadlock bug (#79)

Also update docs