fixed try except, wrong exception: