NXP-15782: fix exception raised frm urllib2.open()