Skip to content

Commit

Permalink
Reduce debug output for German Wiktionary
Browse files Browse the repository at this point in the history
- Catches and passes inflection-tables in the parse tree
- Catches and passes the "Kategorie" links in the parse tree

This work is a contribution to the EWOK project, which receives funding from LABEX ASLAN (ANR–10–LABX–0081) at the Université de Lyon, as part of the "Investissements d'Avenir" program initiated and overseen by the Agence Nationale de la Recherche (ANR) in France.
  • Loading branch information
empiriker committed Oct 19, 2023
1 parent 835cec3 commit 1f8e914
Showing 1 changed file with 17 additions and 1 deletion.
18 changes: 17 additions & 1 deletion src/wiktextract/extractor/de/page.py
Original file line number Diff line number Diff line change
Expand Up @@ -201,7 +201,23 @@ def process_pos_section(
and non_l4_node.kind == NodeKind.TEMPLATE
and "Übersicht" in non_l4_node.template_name
):
# XXX: de: Extract form tables
# XXX: de: Extract form table templates
pass
elif (
isinstance(non_l4_node, WikiNode)
and non_l4_node.kind == NodeKind.TABLE
and "inflection-table" in non_l4_node.attrs.get("class")
):
# XXX: de: Extract html form table
pass
elif (
isinstance(non_l4_node, WikiNode)
and non_l4_node.kind == NodeKind.LINK
and len(non_l4_node.largs) > 0
and len(non_l4_node.largs[0]) > 0
and "Kategorie" in non_l4_node.largs[0][0]
):
# XXX Process categories
pass
else:
wxr.wtp.debug(
Expand Down

0 comments on commit 1f8e914

Please sign in to comment.