Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ValueError: Invalid IPv6 URL #6

Open
lopuhin opened this issue Aug 10, 2020 · 0 comments
Open

ValueError: Invalid IPv6 URL #6

lopuhin opened this issue Aug 10, 2020 · 0 comments

Comments

@lopuhin
Copy link

lopuhin commented Aug 10, 2020

Here is the traceback

  File "/usr/local/lib/python3.6/dist-packages/autopager/autopager.py", line 51, in extract
    return list(get_shared_autopager().extract(page, direct, prev, next))
  File "/usr/local/lib/python3.6/dist-packages/autopager/autopager.py", line 112, in extract
    xseq = page_to_features(links)
  File "/usr/local/lib/python3.6/dist-packages/autopager/model.py", line 129, in page_to_features
    features = [link_to_features(a) for a in xseq]
  File "/usr/local/lib/python3.6/dist-packages/autopager/model.py", line 129, in <listcomp>
    features = [link_to_features(a) for a in xseq]
  File "/usr/local/lib/python3.6/dist-packages/autopager/model.py", line 55, in link_to_features
    p = urlsplit(href)
  File "/usr/lib/python3.6/urllib/parse.py", line 436, in urlsplit
    raise ValueError("Invalid IPv6 URL")
ValueError: Invalid IPv6 URL

Example which triggers the issue (I don't have the one which actually happened in the wild):

autopager.extract('<a href="http://[">Error</a>')
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant