Skip to content

Commit

Permalink
Merge pull request #201 from ickc/dep
Browse files Browse the repository at this point in the history
panflute v2.1.3: Support pandoc 2.16 & upgrade dependencies
  • Loading branch information
sergiocorreia authored Nov 30, 2021
2 parents d00acff + 6013950 commit a0fffbd
Show file tree
Hide file tree
Showing 5 changed files with 45 additions and 31 deletions.
55 changes: 33 additions & 22 deletions .github/workflows/run_tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,28 +22,39 @@ jobs:
max-parallel: 5
matrix:
# see setup.py for supported versions
python-version: [3.6, 3.7, 3.8, 3.9, pypy3]
# should test sparingly across API breaking boundaries
pandoc-version:
# earliest supported pandoc version
- 2.11.0.4
# - 2.11.1
# - 2.11.1.1
# - 2.11.2
# - 2.11.3
# - 2.11.3.1
# - 2.11.3.2
# - 2.11.4
# - 2.12
- latest
# tests multiple versions of `install_requires` when we want to expand the support matrix
click-version:
# - 'click>=6,<7'
# - 'click>=7,<8'
- 'click>=8,<9'
pyyaml-version:
# - 'pyyaml>=3,<4'
- 'pyyaml>=5,<6'
# here instead of having a matrix to test against 7 * 7 * 3 * 3 combinations
# we only test 7 combinations in a round-robin fashion
# make sure the versions are monotmonic increasing w.r.t. each other
# other wise e.g. an older version of a dependency may not work well with a newer version of Python
include:
- python-version: "3.6"
pandoc-version: "2.11.0.4"
click-version: "click>=6,<7"
pyyaml-version: "pyyaml>=3,<4"
- python-version: "pypy-3.6"
pandoc-version: "2.12"
click-version: "click>=6,<7"
pyyaml-version: "pyyaml>=3,<4"
- python-version: "3.7"
pandoc-version: "2.13"
click-version: "click>=7,<8"
pyyaml-version: "pyyaml>=5,<6"
- python-version: "pypy-3.7"
pandoc-version: "2.14.2"
click-version: "click>=7,<8"
pyyaml-version: "pyyaml>=5,<6"
- python-version: "3.8"
pandoc-version: "2.15"
click-version: "click>=8,<9"
pyyaml-version: "pyyaml>=6,<7"
- python-version: "3.9"
pandoc-version: "2.16.2"
click-version: "click>=8,<9"
pyyaml-version: "pyyaml>=6,<7"
- python-version: "3.10"
pandoc-version: "latest"
click-version: "click>=8,<9"
pyyaml-version: "pyyaml>=6,<7"
steps:
- uses: actions/checkout@v2
- name: Set up Python ${{ matrix.python-version }}
Expand Down
13 changes: 7 additions & 6 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -57,12 +57,13 @@ pandoc versioning semantics is [MAJOR.MAJOR.MINOR.PATCH](https://pvp.haskell.org

<!-- For pandoc API verion, check https://hackage.haskell.org/package/pandoc for pandoc-types, which is the same thing. -->

| panflute version | supported pandoc versions | supported pandoc API versions |
| --- | --- | --- |
| 2.1 | 2.11.0.4—2.14.x | 1.22 |
| 2.0 | 2.11.0.4—2.11.x | 1.22 |
| not supported | 2.10 | 1.21 |
| 1.12 | 2.7-2.9 | 1.17.5–1.20 |
| panflute version | supported pandoc versions | supported pandoc API versions |
| ---------------- | ------------------------- | ----------------------------- |
| 2.1.3 | 2.11.0.4–2.16.x | 1.22–1.22.1 |
| 2.1 | 2.11.0.4—2.14.x | 1.22 |
| 2.0 | 2.11.0.4—2.11.x | 1.22 |
| not supported | 2.10 | 1.21 |
| 1.12 | 2.7-2.9 | 1.17.5–1.20 |

Note: pandoc 2.10 is short lived and 2.11 has minor API changes comparing to that, mainly for fixing its shortcomings. Please avoid using pandoc 2.10.

Expand Down
2 changes: 1 addition & 1 deletion panflute/version.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,4 @@
Panflute version
"""

__version__ = '2.1.2'
__version__ = '2.1.3'
3 changes: 2 additions & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -74,6 +74,7 @@
'Programming Language :: Python :: 3.7',
'Programming Language :: Python :: 3.8',
'Programming Language :: Python :: 3.9',
'Programming Language :: Python :: 3.10',
'Programming Language :: Python :: Implementation :: CPython',
'Programming Language :: Python :: Implementation :: PyPy'
],
Expand All @@ -92,7 +93,7 @@
# https://packaging.python.org/en/latest/requirements.html
install_requires=[
'click >=6,<9',
'pyyaml >=3,<6',
'pyyaml >=3,<7',
],

# List additional groups of dependencies here (e.g. development
Expand Down
3 changes: 2 additions & 1 deletion tests/filters/assert_env.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,8 @@ def prepare(doc):
pf.debug(f' {k}={v}')

assert doc.pandoc_version >= (2, 11, 0)
assert doc.pandoc_reader_options['readerStandalone'] is False
standalone_key = 'readerStandalone' if doc.pandoc_version < (2, 16, 0) else "standalone"
assert doc.pandoc_reader_options[standalone_key] is False


def action(elem, doc):
Expand Down

0 comments on commit a0fffbd

Please sign in to comment.