Closed
Description
Pandoc versions 2.16 and newer don't accept empty metadata.yml files anymore. However, an empty file is indeed valid YAML. (I am using automated processing of Markdown input where sometimes, the metadata.yml is empty. That's how the issue came to light.)
This can be reproduced by simply using --metadata-file /dev/null
as an "empty metadata file":
$ pandoc -f markdown -t pdf -o /dev/null --metadata-file /dev/null /dev/null
Error at "/dev/null" (line 1, column 1):
expected YAML object
The above command works fine with Pandoc 2.15. Therefore, the bug happened somewhere between 2.15 and 2.16.