diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index 5dab43e..c955407 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -24,9 +24,9 @@ jobs: runs-on: ${{ matrix.os }} strategy: matrix: - python-version: ['3.9', '3.13', '3.14-dev'] + python-version: ['3.10', '3.13', '3.14', '3.15-dev'] os: [ubuntu-latest, macos-latest, windows-latest] - continue-on-error: ${{ matrix.python-version == '3.14-dev' }} + continue-on-error: ${{ matrix.python-version == '3.15-dev' }} steps: - uses: actions/checkout@v4 @@ -49,7 +49,7 @@ jobs: # FYI: Requires token to continue usage # - name: Upload to Codecov - # if: matrix.os == 'ubuntu-latest' && matrix.python-version == 3.9 + # if: matrix.os == 'ubuntu-latest' && matrix.python-version == '3.10' # uses: codecov/codecov-action@v1 # with: # name: pytests @@ -65,7 +65,7 @@ jobs: - name: Set up Python uses: actions/setup-python@v2 with: - python-version: 3.9 + python-version: '3.10' - name: Installation (deps and package) run: | @@ -87,7 +87,7 @@ jobs: - name: Set up Python uses: actions/setup-python@v5 with: - python-version: 3.9 + python-version: '3.10' - name: install flit run: | pip install flit~=3.0 diff --git a/mdformat_myst/plugin.py b/mdformat_myst/plugin.py index 077ce15..88f2a1a 100644 --- a/mdformat_myst/plugin.py +++ b/mdformat_myst/plugin.py @@ -23,11 +23,11 @@ def update_mdit(mdit: MarkdownIt) -> None: mdit.options["parser_extension"].append(tables_plugin) tables_plugin.update_mdit(mdit) - # Enable mdformat-frontmatter plugin - frontmatter_plugin = mdformat.plugins.PARSER_EXTENSIONS["frontmatter"] - if frontmatter_plugin not in mdit.options["parser_extension"]: - mdit.options["parser_extension"].append(frontmatter_plugin) - frontmatter_plugin.update_mdit(mdit) + # Enable mdformat-front-matters plugin + front_matters_plugin = mdformat.plugins.PARSER_EXTENSIONS["front_matters"] + if front_matters_plugin not in mdit.options["parser_extension"]: + mdit.options["parser_extension"].append(front_matters_plugin) + front_matters_plugin.update_mdit(mdit) # Enable mdformat-footnote plugin footnote_plugin = mdformat.plugins.PARSER_EXTENSIONS["footnote"] diff --git a/pyproject.toml b/pyproject.toml index 605f2b1..19c5378 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -18,14 +18,13 @@ classifiers = [ ] keywords = "mdformat,markdown,formatter,gfm" -requires-python=">=3.9" -requires=[ +requires-python = ">=3.10" +requires = [ "mdformat >=0.7.0", "mdit-py-plugins >=0.3.0", - "mdformat-tables >=0.4.0; python_version < '3.10'", - "mdformat-frontmatter >=0.3.2", + "mdformat-front-matters >= 1.0.0", "mdformat-footnote >=0.1.1", - "mdformat-gfm >=1.0.0; python_version >= '3.10'", + "mdformat-gfm >=1.0.0", "ruamel.yaml >=0.16.0", ] diff --git a/tox.ini b/tox.ini index 3f8959b..8729f36 100644 --- a/tox.ini +++ b/tox.ini @@ -1,15 +1,15 @@ [tox] -envlist = py39 +envlist = py310 isolated_build = True -[testenv:py{39,311,313}] +[testenv:py{310,314,315}] extras = test deps = black flake8 commands = pytest {posargs} -[testenv:py{39,311,313}-hook] +[testenv:py{310,314,315}-hook] commands = pre-commit run --config .pre-commit-test.yaml {posargs:--all-files --verbose --show-diff-on-failure} [flake8]