Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Filters not working under pandoc 2.13 #14

Closed
calliecameron opened this issue Apr 27, 2022 · 2 comments
Closed

Filters not working under pandoc 2.13 #14

calliecameron opened this issue Apr 27, 2022 · 2 comments
Labels
question Further information is requested

Comments

@calliecameron
Copy link
Contributor

Looks like the fix for #12 broke the filters on pandoc 2.13:

$ cd test
$ bash run.sh

        ================== Bash Tests ==================

        1. [Short] Single input
        ----------------------------------------
Creating temporary directory.
Directory created: /tmp/tmp.sPGFL1y3uF
Extracting /home/callie/pandoc-templates/shunn/short/template.docx to temporary directory.
Files extracted.
Running Pandoc.
Error running filter /home/callie/pandoc-templates/shunn/short/shunnshort.lua:
/home/callie/pandoc-templates/filters/meta.lua:5: attempt to call a nil value (field 'type')
stack traceback:
        /home/callie/pandoc-templates/filters/meta.lua:5: in function 'Meta'
Pandoc completed successfully.
Removing /tmp/tmp.sPGFL1y3uF
Done.
        2. [Long] Wildcard
        ----------------------------------------
Creating temporary directory.
Directory created: /tmp/tmp.06CaCk20OO
Extracting /home/callie/pandoc-templates/shunn/long/template.docx to temporary directory.
Files extracted.
Running Pandoc.
Error running filter /home/callie/pandoc-templates/shunn/long/shunnlong.lua:
/home/callie/pandoc-templates/filters/meta.lua:5: attempt to call a nil value (field 'type')
stack traceback:
        /home/callie/pandoc-templates/filters/meta.lua:5: in function 'Meta'
Pandoc completed successfully.
Removing /tmp/tmp.06CaCk20OO
Done.

        =============== Powershell Tests ===============

        1. [Short] Single input
        ----------------------------------------
run.sh: line 24: pwsh: command not found
        2. [Short] Various line break conventions
        ----------------------------------------
run.sh: line 27: pwsh: command not found
        3. [Long] Multiple wildcard inputs
        ----------------------------------------
run.sh: line 31: pwsh: command not found

Expected behavior

As seen on the previous commit:

$ cd test
$ bash run.sh


        ================== Bash Tests ==================

        1. [Short] Single input
        ----------------------------------------
Creating temporary directory.
Directory created: /tmp/tmp.GkNGDAdrsT
Extracting /home/callie/pandoc-templates/shunn/short/template.docx to temporary directory.
Files extracted.
Running Pandoc.
Zipping reference.docx using UNIX zip.
Pandoc completed successfully.
Removing /tmp/tmp.GkNGDAdrsT
Done.
        2. [Long] Wildcard
        ----------------------------------------
Creating temporary directory.
Directory created: /tmp/tmp.7YK7sU6O0a
Extracting /home/callie/pandoc-templates/shunn/long/template.docx to temporary directory.
Files extracted.
Running Pandoc.
Zipping reference.docx using UNIX zip.
Pandoc completed successfully.
Removing /tmp/tmp.7YK7sU6O0a
Done.

        =============== Powershell Tests ===============

        1. [Short] Single input
        ----------------------------------------
run.sh: line 24: pwsh: command not found
        2. [Short] Various line break conventions
        ----------------------------------------
run.sh: line 27: pwsh: command not found
        3. [Long] Multiple wildcard inputs
        ----------------------------------------
run.sh: line 31: pwsh: command not found

Environment (please complete the following information):

  • OS: Linux Mint 20.1 Cinnamon
  • Pandoc Version: 2.13
  • Version: commit e28b04f
@calliecameron calliecameron added the bug Something isn't working label Apr 27, 2022
@davidlday
Copy link
Contributor

True. There were breaking changes in release 2.17 of Pandoc that caused the need for this change. I'm not sure at this point there would be a way to support both versions. Any chance of upgrading to Pandoc 2.17 or greater?

@davidlday davidlday added question Further information is requested and removed bug Something isn't working labels Apr 28, 2022
@calliecameron
Copy link
Contributor Author

Noted. I can't currently upgrade pandoc because of a bug in pandoc, so I'll keep using the commit that works with old versions for now.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
question Further information is requested
Projects
None yet
Development

No branches or pull requests

2 participants