Tacsipacsi reopened this task as "Open".
Tacsipacsi added a comment.

Now it sometimes misses sections. For example, hu:User talk:Wegyor’s sections from “Segítséget kértél, és én...” until “Családfa rajzokhoz...” (inclusive) are not discovered. I checked it with the following code:

class DiscussionPage(pywikibot.Page):
    ...
    def load_page(self):
        ...
        thread_titles = []
        for line_number, line in enumerate(lines, start=1):
            if line_number in thread_headers:
                thread_header = re.search('^== *([^=].*?) *== *$', line)
                thread_titles.append(thread_header.group(1))
                found = True  # Reading threads now
                if cur_thread:
                    self.threads.append(cur_thread)
                cur_thread = DiscussionThread(thread_header.group(1), self.now,
                                              self.timestripper)
            else:
                if found:
                    cur_thread.feed_line(line)
                else:
                    self.header += line + '\n'
        if cur_thread:
            self.threads.append(cur_thread)
        pywikibot.output('Thread titles: %s' % thread_titles)
        ...

TASK DETAIL
https://phabricator.wikimedia.org/T182496

EMAIL PREFERENCES
https://phabricator.wikimedia.org/settings/panel/emailpreferences/

To: Dvorapa, Tacsipacsi
Cc: Xqt, gerritbot, Ato_01, Tacsipacsi, revi, Dvorapa, Aklapper, jeblad, Ghouston, whym, pywikibot-bugs-list, Cpaulf30, Baloch007, Darkminds3113, Lordiis, Adik2382, Th3d3v1ls, Ramalepe, Liugev6, Lewizho99, Maathavan
_______________________________________________
pywikibot-bugs mailing list
pywikibot-bugs@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/pywikibot-bugs

Reply via email to