Closed dbobak closed 6 years ago
I have the same error using both pythons on windows 10 (all commands executed in powershell).
pandoc README.md -s --toc --mathjax --css css/pandoc.css --highlight-style pygments -V geometry:margin=1in --pdf-engine=xelatex --bibliography ref/references.bib --filter pandoc-fignos --filter pandoc-tablenos --filter pandoc-citeproc -
-table-of-contents --csl ref/ieee.csl -o README.html
This bash script was working with no errors a few months ago. I have since updated pandoc
.
It now returns:
Traceback (most recent call last):
File "C:\Program Files\Pandoc\pandoc-fignos-script.py", line 11, in <module>
load_entry_point('pandoc-fignos==1.2.0', 'console_scripts', 'pandoc-fignos')()
File "c:\python27\lib\site-packages\pandoc_fignos.py", line 415, in main
process(meta)
File "c:\python27\lib\site-packages\pandoc_fignos.py", line 354, in process
assert use_cleveref_default in [True, False]
AssertionError
Error running filter pandoc-fignos:
Filter returned error status 1
I tried deleting the fignos.py script in my C:\Program Files\Pandoc folder
, and reinstalling pandoc-fignos
, but this didn't change anything.
pandoc -v
pandoc.exe 2.2.3
Compiled with pandoc-types 1.17.5.1, texmath 0.11.0.1, skylighting 0.7.2
Default user data directory: C:\Users\hd1213\AppData\Roaming\pandoc
Copyright (C) 2006-2018 John MacFarlane
Web: http://pandoc.org
This is free software; see the source for copying conditions.
There is no warranty, not even for merchantability or fitness
for a particular purpose.
python
Python 2.7.14 (v2.7.14:84471935ed, Sep 16 2017, 20:25:58) [MSC v.1500 64 bit (AMD64)] on win32
pip show pandoc-fignos
Name: pandoc-fignos
Version: 1.2.0
Summary: Figure number filter for pandoc
Home-page: https://github.com/tomduck/pandoc-fignos
Author: Thomas J. Duck
Author-email: tomduck@tomduck.ca
License: GPL
Location: c:\python27\lib\site-packages
Requires: pandoc-xnos
Required-by:
I thought it might be a python version issue, so I tried installing python3 on the same machine, but get the same error:
pandoc README.md -s --toc --mathjax --css css/pandoc.css --highlight-style pygments -V geometry:margin=1in --pdf-engine=xelatex --bibliography ref/references.bib --filter pandoc-fignos --filter pandoc-tablenos --filter pandoc-citeproc -
-table-of-contents --csl ref/ieee.csl -o README.html
Traceback (most recent call last):
File "C:\Program Files\Pandoc\pandoc-fignos-script.py", line 11, in <module>
load_entry_point('pandoc-fignos==1.2.0', 'console_scripts', 'pandoc-fignos')()
File "c:\users\hd1213\appdata\local\programs\python\python37\lib\site-packages\pandoc_fignos.py", line 415, in main
process(meta)
File "c:\users\hd1213\appdata\local\programs\python\python37\lib\site-packages\pandoc_fignos.py", line 354, in process
assert use_cleveref_default in [True, False]
AssertionError
Error running filter pandoc-fignos:
Filter returned error status 1
I have just tried to replicate this error on Ubuntu 18.04LTS linux and found that pandoc-fignos
works fine with pandoc
version 1.19.2.4
, but this error appears when I upgrade to pandoc
version 2.2.3
, I hope this helps.
Additionally, pip
seems to be complaining about not being able to find a version of pandoc-citeproc
which satisfies requirements. Maybe this is the root cause?
pip install pandoc-fignos pandoc-citeproc pandoc-eqnos pandoc-tablenos
Requirement already satisfied: pandoc-fignos in /usr/local/lib/python2.7/dist-packages (1.2.0)
Collecting pandoc-citeproc
Could not find a version that satisfies the requirement pandoc-citeproc (from versions: )
No matching distribution found for pandoc-citeproc
pip3 install pandoc-fignos pandoc-citeproc pandoc-eqnos pandoc-tablenos
Requirement already satisfied: pandoc-fignos in /usr/local/lib/python3.6/dist-packages (1.2.0)
Collecting pandoc-citeproc
Could not find a version that satisfies the requirement pandoc-citeproc (from versions: )
No matching distribution found for pandoc-citeproc
The pandoc error is idential to that given by windows (see comments above).
I hope this helps.
Yes, it would appear that pandoc has made a change to how it is handling boolean metadata. I think that I have likely fixed it in the pandoc-xnos nextrelease repo. All of my regression tests (which include cleveref handling) are passing. Stay tuned.
I just tried again with the pandoc
update (version 2.2.3.2 as you suggest), and I'm afraid it makes no difference. This bug is still present withpandoc
version 2.2.3.2.
I have found that downgrading to pandoc
1.19.2.4 kills this bug. I hope this helps. Thanks @tomduck.
Confirmed. The issue is still with pandoc 2.2.3.2.
There is a behaviour change in pandoc's treatment of boolean metadata values: true
, True
and TRUE
are all accepted, but On
is not any more. See the release notes for pandoc 2.2.2.
Please let me know if changing your metadata solves the problem you are experiencing.
I will look at introducing a more helpful error message, and will update the documentation.
Yes, that was the problem. Changing On
to true
and Off
to false
did the trick. It's working perfectly now. Thank you!
Yes, I can confirm that this fixed the problem on Windows and Linux. Thank you both. This issue can now be closed I think. Perhaps state the now required syntax in the README? I have created a suitable pull request #53 @tomduck . Hope this helps.
OK, great. I had already made the requisite updates to the README.md
in the nextrelease
branch. Still, thank you for the pull request. Contributions to the code and documentation are very much appreciated.
I will close this now in anticipation of putting out a new release today.
Cheers, Tom
Pandoc 2.2.2.1, Python 3.6.6 on Windows 10. I'm receiving the following error: