- req = urllib2.Request(url=control_url + "/queue.gz", headers=headers)
- f = urllib2.urlopen(req)
-except Exception, e:
- print >> sys.stderr, "Fetch error %s: %s" % (control_url + "/queue.gz", e)
+ req = request.Request(url=control_url + "/queue.gz", headers=headers)
+ f = request.urlopen(req)
+except Exception as e:
+ print("Fetch error %s: %s" % (control_url + "/queue.gz", e), file=sys.stderr)