set timeout to prevent urlopen hang