[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Bug#682603: unblock: linkchecker/7.9-2.1



Package: release.debian.org
Severity: normal
User: release.debian.org@packages.debian.org
Usertags: unblock

Please unblock package linkchecker

Fixes RC bug #681069.  Right now this isn't strictly essential since the
Python version (2.7.3) that induces this bug isn't in Wheezy, but the fix is
perfectly safe no matter what we do with python2.7, so I think it's better to
let it through so we don't have to worry about remembering to unblock it
later.

unblock linkchecker/7.9-2.1
diff -Nru linkchecker-7.9/debian/changelog linkchecker-7.9/debian/changelog
--- linkchecker-7.9/debian/changelog	2012-06-12 01:33:19.000000000 -0400
+++ linkchecker-7.9/debian/changelog	2012-07-23 23:03:31.000000000 -0400
@@ -1,3 +1,14 @@
+linkchecker (7.9-2.1) unstable; urgency=low
+
+  * Non-maintainer upload.
+  * Add url definition lists deleted from Python's urlparser.py to
+    linkcheckers' linkcheck/url.py and refer to the local copies to fix three
+    sources of crashes (the Python versions are present in 2.7.3~rc2 and
+    missing from 2.7.3 final - this patched version will work with either)
+    (Closes: #681069)
+
+ -- Scott Kitterman <scott@kitterman.com>  Mon, 23 Jul 2012 22:57:47 -0400
+
 linkchecker (7.9-2) unstable; urgency=low
 
   * Fix postinstallation script of linkchecker-web. (Closes: #677163)
diff -Nru linkchecker-7.9/debian/patches/fix_2_7_3_breakage.patch linkchecker-7.9/debian/patches/fix_2_7_3_breakage.patch
--- linkchecker-7.9/debian/patches/fix_2_7_3_breakage.patch	1969-12-31 19:00:00.000000000 -0500
+++ linkchecker-7.9/debian/patches/fix_2_7_3_breakage.patch	2012-07-23 23:05:55.000000000 -0400
@@ -0,0 +1,57 @@
+Description: Add url definition lists deleted from Python's urlparser.py
+ linkchecker (7.9-2.1) unstable; urgency=low
+ .
+   * Non-maintainer upload.
+   * Add url definition lists deleted from Python's urlparser.py to
+     linkcheckers' linkcheck/url.py and refer to the local copies to fix three
+     sources of crashes (the Python versions are present in 2.7.3~rc2 and
+     missing from 2.7.3 final - this patched version will work with either)
+     (Closes: #681069)
+Author: Scott Kitterman <scott@kitterman.com>
+Bug-Debian: http://bugs.debian.org/681069
+Origin: <vendor>
+Bug-Debian: http://bugs.debian.org/<bugnumber>
+Forwarded: <no>
+Last-Update: <2012-07-23>
+
+--- linkchecker-7.9.orig/linkcheck/url.py
++++ linkchecker-7.9/linkcheck/url.py
+@@ -28,6 +28,17 @@ import socket
+ from . import httplib2 as httplib
+ from . import log, LOG_CHECK
+ 
++# The following lists were removed from the final release of Python 2.7.3, so
++# they are replicated here so that linkchecker can make use of them.
++
++non_hierarchical = ['gopher', 'hdl', 'mailto', 'news',
++                    'telnet', 'wais', 'imap', 'snews', 'sip', 'sips']
++uses_query = ['http', 'wais', 'imap', 'https', 'shttp', 'mms',
++              'gopher', 'rtsp', 'rtspu', 'sip', 'sips', '']
++uses_fragment = ['ftp', 'hdl', 'http', 'gopher', 'news',
++                 'nntp', 'wais', 'https', 'shttp', 'snews',
++                 'file', 'prospero', '']
++
+ for scheme in ('ldap', 'irc'):
+     if scheme not in urlparse.uses_netloc:
+         urlparse.uses_netloc.append(scheme)
+@@ -69,9 +80,9 @@ if sys.version_info[0] > 2 or sys.versio
+                 scheme, url = url[:i].lower(), url[i+1:]
+         if url[:2] == '//':
+             netloc, url = urlparse._splitnetloc(url, 2)
+-        if allow_fragments and scheme in urlparse.uses_fragment and '#' in url:
++        if allow_fragments and scheme in uses_fragment and '#' in url:
+             url, fragment = url.split('#', 1)
+-        if scheme in urlparse.uses_query and '?' in url:
++        if scheme in uses_query and '?' in url:
+             url, query = url.split('?', 1)
+         v = urlparse.SplitResult(scheme, netloc, url, query, fragment)
+         urlparse._parse_cache[key] = v
+@@ -344,7 +355,7 @@ def url_norm (url, encoding=None):
+     is_idn = url_fix_host(urlparts)
+     # query
+     urlparts[3] = url_parse_query(urlparts[3], encoding=encoding)
+-    is_hierarchical = urlparts[0] not in urlparse.non_hierarchical
++    is_hierarchical = urlparts[0] not in non_hierarchical
+     if is_hierarchical:
+         # URL has a hierarchical path we should norm
+         if not urlparts[2]:
diff -Nru linkchecker-7.9/debian/patches/series linkchecker-7.9/debian/patches/series
--- linkchecker-7.9/debian/patches/series	1969-12-31 19:00:00.000000000 -0500
+++ linkchecker-7.9/debian/patches/series	2012-07-23 23:04:03.000000000 -0400
@@ -0,0 +1 @@
+fix_2_7_3_breakage.patch

Reply to: