Skip to content

Crash - panflute "invalid API version" #12

@lezsakdomi

Description

@lezsakdomi

I've just issued pip install pandoc-plantuml-filter; pip install -U pandoc-mustache on WSL with ubuntu-20.04, and tried running pandoc with both filters.

Here is the console output:

Traceback (most recent call last):
  File "/home/led/.local/bin//pandoc-mustache", line 8, in <module>
    sys.exit(main())
  File "/home/led/.local/lib/python3.8/site-packages/pandoc_mustache/pandoc_mustache.py", line 36, in main
    return run_filter(action, prepare=prepare, doc=doc)
  File "/home/led/.local/lib/python3.8/site-packages/panflute/io.py", line 224, in run_filter
    return run_filters([action], *args, **kwargs)
  File "/home/led/.local/lib/python3.8/site-packages/panflute/io.py", line 197, in run_filters
    doc = load(input_stream=input_stream)
  File "/home/led/.local/lib/python3.8/site-packages/panflute/io.py", line 58, in load
    doc = json.load(input_stream, object_hook=from_json)
  File "/usr/lib/python3.8/json/__init__.py", line 293, in load
    return loads(fp.read(),
  File "/usr/lib/python3.8/json/__init__.py", line 370, in loads
    return cls(**kw).decode(s)
  File "/usr/lib/python3.8/json/decoder.py", line 337, in decode
    obj, end = self.raw_decode(s, idx=_w(s, 0).end())
  File "/usr/lib/python3.8/json/decoder.py", line 353, in raw_decode
    obj, end = self.scan_once(s, idx)
  File "/home/led/.local/lib/python3.8/site-packages/panflute/elements.py", line 1353, in from_json
    return Doc(*items, api_version=api, metadata=meta)
  File "/home/led/.local/lib/python3.8/site-packages/panflute/elements.py", line 66, in __init__
    raise TypeError("invalid api version", api_version)
TypeError: ('invalid api version', [1, 17, 5, 4])
Error running filter pandoc-mustache:
Filter returned error status 1

Can you reproduce this bug?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions