fix bugs discovered in testing DRL