mwparserfromhell icon indicating copy to clipboard operation
mwparserfromhell copied to clipboard

`}}` in parameter value wrongly recognized as end of template

Open not-my-profile opened this issue 3 years ago • 0 comments

text = '''
{{hello
|foo={{A}, {B}}
|bar=123
}}
'''

import mwparserfromhell

print(mwparserfromhell.parse(text).filter_templates())

Expected output:

['{{hello\n|foo={{A}, {B}}\n|bar=123\n}}']

Received output:

['{{hello\n|foo={{A}, {B}}']

not-my-profile avatar Jul 11 '22 23:07 not-my-profile