I am trying to add items to an empty set from a list after checking if the page is rooted with the isRooted function.
uniqueUrl = set()
for url in urlList:
if(isRooted(rootURL,url[0])):
uniqueURL.add(url[0])
This is the error I am recieving:
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "C:\Python32\webcrawl.py", line 119, in crawl
uniqueURL.add(url[0])
NameError: global name 'uniqueURL' is not defined
Caps are different in the two variables.