The problem is probably that you're catching all exceptions. Something is probably raising an exception in one of the other lines, and your catch-all clause is being triggered.
Don't do that. Find out which exceptions you're expecting, and only catch them. Anything else is a legitimate error and should bubble up.