Skip to content

Commit

Permalink
Remove the limit of unnamed template argument number
Browse files Browse the repository at this point in the history
0 and above 1000 are allowed in MediaWiki, for example, fr edition's
"cardinaux/vi" template:
https://fr.wiktionary.org/wiki/Modèle:cardinaux/vi
  • Loading branch information
xxyzz committed Apr 25, 2024
1 parent 1330408 commit 73f6ec8
Showing 1 changed file with 0 additions and 7 deletions.
7 changes: 0 additions & 7 deletions src/wikitextprocessor/core.py
Original file line number Diff line number Diff line change
Expand Up @@ -1602,13 +1602,6 @@ def expander(arg: str) -> str:
k, arg = m2.groups()
if k.isdigit():
k = int(k)
if k < 1 or k > 1000:
self.debug(
"invalid argument number {} "
"for template {!r}".format(k, name),
sortid="core/1211",
)
k = 1000
else:
self.expand_stack.append("ARGNAME")
k = expand_recurse(k, parent, True)
Expand Down

0 comments on commit 73f6ec8

Please sign in to comment.