Traceback (most recent call last):
File "xcdn.py", line 288, in
Xcdn(domain)
File "xcdn.py", line 63, in init
actual_ip = self.get_actual_ip_from_domain()
File "xcdn.py", line 276, in get_actual_ip_from_domain
result = self.check_if_mx_c_machines_has_actual_ip_of_domain()
File "xcdn.py", line 228, in check_if_mx_c_machines_has_actual_ip_of_domain
result = self.check_if_ip_c_machines_has_actual_ip_of_domain(each_ip)
File "xcdn.py", line 197, in check_if_ip_c_machines_has_actual_ip_of_domain
if True == self.check_if_ip_is_actual_ip_of_domain(each_ip):
File "xcdn.py", line 156, in check_if_ip_is_actual_ip_of_domain
hosts_changed_domain_title= get_request(self.http_or_https + "://%s" % self.domain,'selenium_phantom_js')['title']
File "/usr/local/lib/python3.7/dist-packages/exp10it.py", line 2075, in get_request
driver.quit()
UnboundLocalError: local variable 'driver' referenced before assignment
【How to solve this problem when I run it by python3.7】
Traceback (most recent call last): File "xcdn.py", line 288, in
Xcdn(domain)
File "xcdn.py", line 63, in init
actual_ip = self.get_actual_ip_from_domain()
File "xcdn.py", line 276, in get_actual_ip_from_domain
result = self.check_if_mx_c_machines_has_actual_ip_of_domain()
File "xcdn.py", line 228, in check_if_mx_c_machines_has_actual_ip_of_domain
result = self.check_if_ip_c_machines_has_actual_ip_of_domain(each_ip)
File "xcdn.py", line 197, in check_if_ip_c_machines_has_actual_ip_of_domain
if True == self.check_if_ip_is_actual_ip_of_domain(each_ip):
File "xcdn.py", line 156, in check_if_ip_is_actual_ip_of_domain
hosts_changed_domain_title= get_request(self.http_or_https + "://%s" % self.domain,'selenium_phantom_js')['title']
File "/usr/local/lib/python3.7/dist-packages/exp10it.py", line 2075, in get_request
driver.quit()
UnboundLocalError: local variable 'driver' referenced before assignment
【How to solve this problem when I run it by python3.7】