- exec("from Robots import bkmk_r%s" % robot_name)
- exec("robot = bkmk_r%s.robot_%s" % (robot_name, robot_name))
- return robot
+ if (robot_name == 'urllib') and (sys.version_info[0] >= 3):
+ robot_name = 'urllib_py3'
+ ns = locals()
+ exec("from Robots import bkmk_r%s" % robot_name, globals(), ns)
+ exec("robot = bkmk_r%s.robot_%s" % (robot_name, robot_name), globals(), ns)
+ return ns['robot']
+