fixing bugs, changing from threaded to single thread for debugging purposes