Skip to content

Commit

Permalink
Fix testing on old Python versions
Browse files Browse the repository at this point in the history
  • Loading branch information
jstrieb committed Dec 21, 2023
1 parent 72b9120 commit 0fbb283
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 5 deletions.
6 changes: 5 additions & 1 deletion .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -47,10 +47,14 @@ jobs:
fail-fast: false
matrix:
os: [ubuntu-latest]
python-version: ['3.6', '3.7', '3.8', '3.9', '3.10', '3.11', '3.12']
python-version: ['3.8', '3.9', '3.10', '3.11', '3.12']
include:
- os: macos-latest
python-version: '3.8'
- os: 'ubuntu-20.04'
python-version: '3.6'
- os: 'ubuntu-20.04'
python-version: '3.7'
runs-on: ${{ matrix.os }}
steps:
- uses: actions/checkout@v4
Expand Down
4 changes: 2 additions & 2 deletions just_sh/parse.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
import re
import sys
from dataclasses import dataclass
from typing import Any, Callable, List, Optional, TextIO, Tuple, Union, cast
from typing import Any, Callable, List, Optional, TextIO, Tuple, Type, Union, cast

from parsy import (
Parser,
Expand Down Expand Up @@ -520,7 +520,7 @@ def _body() -> Parser:
return cast(List[Item], justfile_parser.parse(preprocess(data)))


def run(f: TextIO, encoder: type[json.JSONEncoder], verbose: bool = False) -> None:
def run(f: TextIO, encoder: Type[json.JSONEncoder], verbose: bool = False) -> None:
print(json.dumps(parse(f.read(), verbose=verbose), cls=encoder, indent=2))


Expand Down
3 changes: 1 addition & 2 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
########################################################################################

[build-system]
requires = ["setuptools >= 61.0", "setuptools_scm >= 8"]
requires = ["setuptools >= 59.6.0", "setuptools_scm >= 6.4.2"]
build-backend = "setuptools.build_meta"

[tool.setuptools.package-dir]
Expand Down Expand Up @@ -37,7 +37,6 @@ classifiers = [
"Intended Audience :: Developers",
"License :: OSI Approved :: GNU General Public License v3 (GPLv3)",
"Operating System :: OS Independent",
# "Programming Language :: Unix Shell",
"Programming Language :: Python :: 3",
"Topic :: Software Development",
"Topic :: Software Development :: Code Generators",
Expand Down

0 comments on commit 0fbb283

Please sign in to comment.