以下のコードの iterlink で「'NoneType' object is not iterable」というエラーが発生します。誰か助けてくれませんか?
from lxml import html
source=urllib.request.urlopen("http://google.com").read()
tree=html.document_fromstring(source)
for i in tree.iterlinks:
print(i)
以下のコードの iterlink で「'NoneType' object is not iterable」というエラーが発生します。誰か助けてくれませんか?
from lxml import html
source=urllib.request.urlopen("http://google.com").read()
tree=html.document_fromstring(source)
for i in tree.iterlinks:
print(i)