Skip to content

Commit

Permalink
Fix GitHub workflow (#7)
Browse files Browse the repository at this point in the history
* quote python versions so they are properly parsed

* get Iterable from collections.abc to address error in 3.10, fix pre-commit issue
  • Loading branch information
Mraoul authored Feb 15, 2022
1 parent 8d67a6c commit 91b05fa
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 5 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/run-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ jobs:
runs-on: ubuntu-latest
strategy:
matrix:
python: [3.7, 3.8, 3.9, 3.10]
python: ['3.7', '3.8', '3.9', '3.10']
steps:
- uses: actions/checkout@v2
- name: Setup Python
Expand Down
9 changes: 6 additions & 3 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -10,13 +10,16 @@ repos:
- id: debug-statements
- id: name-tests-test
args:
- "--django"
- "--django"
- repo: https://gitlab.com/pycqa/flake8.git
rev: 3.7.9
hooks:
- id: flake8
- repo: https://github.com/pre-commit/mirrors-mypy.git
rev: v0.761
rev: v0.931
hooks:
- id: mypy
args: [--ignore-missing-imports]
args:
- "--install-types"
- "--non-interactive"
- "--ignore-missing-imports"
3 changes: 2 additions & 1 deletion d20/Manual/Shell.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
import sys
import cmd
import collections
import collections.abc
import datetime
import copy
import yaml
Expand Down Expand Up @@ -54,7 +55,7 @@ def prettyList(data: Dict, debug: bool = False) -> str:
filler: int = len(key) - hwidth
if (isinstance(
value,
collections.Iterable) and not isinstance(value, str)):
collections.abc.Iterable) and not isinstance(value, str)):
table += "%s %*s\n" % (key, filler, '')
for d in value:
table += "%*s %*s%s\n" % (len(key), '', filler, '', d)
Expand Down

0 comments on commit 91b05fa

Please sign in to comment.