Skip to content
Permalink
Browse files
hey, I used lxml wrong! Also, fix #1776
  • Loading branch information
ralsina committed Jun 1, 2015
1 parent 20b97c4 commit 403036b67f800d17feb5f3dfeb1517509a3614e7
Showing 1 changed file with 2 additions and 1 deletion.
@@ -200,7 +200,7 @@ def analyze(self, fname, find_sources=False, check_remote=False):

d = lxml.html.fromstring(open(filename, 'rb').read())
for l in d.iterlinks():
target = l[0].attrib[l[1]]
target = l[2]
if target == "#":
continue
target, _ = urldefrag(target)
@@ -260,6 +260,7 @@ def analyze(self, fname, find_sources=False, check_remote=False):
self.existing_targets.add(target_filename)
else:
rv = True
import pdb; pdb.set_trace()
self.logger.warn("Broken link in {0}: {1}".format(filename, target))
if find_sources:
self.logger.warn("Possible sources:")

0 comments on commit 403036b

Please sign in to comment.