diff --git a/.github/workflows/isort-and-black-checks.yml b/.github/workflows/isort-and-black-checks.yml index 1b7863f..0353d39 100644 --- a/.github/workflows/isort-and-black-checks.yml +++ b/.github/workflows/isort-and-black-checks.yml @@ -14,12 +14,10 @@ jobs: uses: actions/setup-python@v5 with: python-version: 3.11 - - name: Install click - run: pip install 'click==8.0.4' - - name: Install Black - run: pip install 'black==22.3.0' - - name: Run black --check . - run: black --check . + - name: Install click, black and isort + run: pip install 'click==8.2.1' 'black==25.11.0' 'isort==5.13.2' + - name: Run black --check --diff . + run: black --check --diff . - name: If needed, commit black changes to the pull request if: failure() run: | diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index b06e761..7b24bcb 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -14,7 +14,7 @@ repos: - id: trailing-whitespace exclude: ChangeLog-spell-corrected.diff - repo: https://github.com/psf/black - rev: 24.10.0 + rev: 25.11.0 hooks: - id: black language_version: python3 diff --git a/rst2html.py b/rst2html.py index f8aeb83..4595c4a 100755 --- a/rst2html.py +++ b/rst2html.py @@ -48,7 +48,7 @@ def yield_sphinx_only_markup(lines): def clean_line(line): try: - for (regex, sub) in regex_subs: + for regex, sub in regex_subs: line = regex.sub(sub, line) except Exception as ex: print(f"ERROR: {regex}, (line({sub})")