[releng] Fix



commit 35e6722f1efc1a50c57b27603584b7ecd0039e62
Author: Michael Catanzaro <mcatanzaro gnome org>
Date:   Mon Mar 9 11:26:24 2020 -0500

    Fix
    
    I broke the HTML parser in 62c85310, so now only tarballs available via
    SFTP can be downloaded. Update by properly revising our urllister class
    to overload an HTMLParser method rather than an SGMLParser method.
    
    Fixes #13

 tools/smoketesting/convert-to-tarballs.py | 9 +++++----
 1 file changed, 5 insertions(+), 4 deletions(-)
---
diff --git a/tools/smoketesting/convert-to-tarballs.py b/tools/smoketesting/convert-to-tarballs.py
index f59c9a6..d16984a 100755
--- a/tools/smoketesting/convert-to-tarballs.py
+++ b/tools/smoketesting/convert-to-tarballs.py
@@ -247,10 +247,11 @@ class urllister(HTMLParser):
         HTMLParser.reset(self)
         self.urls = []
 
-    def start_a(self, attrs):
-        href = [v for k, v in attrs if k=='href']
-        if href:
-            self.urls.extend(href)
+    def handle_starttag(self, tag, attrs):
+        if tag == 'a':
+            href = [v for k, v in attrs if k=='href']
+            if href:
+                self.urls.extend(href)
 
 class TarballLocator:
     def __init__(self, tarballdir, mirrors, local_only=False):


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