Catch urlopen errors