Skip to content

Commit

Permalink
Fix tests, add python 3.12
Browse files Browse the repository at this point in the history
  • Loading branch information
Eeems committed Dec 16, 2023
1 parent baa84ae commit 043a608
Show file tree
Hide file tree
Showing 3 changed files with 15 additions and 7 deletions.
16 changes: 12 additions & 4 deletions .github/workflows/checks.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,26 +5,34 @@ jobs:
format:
name: Check formatting
runs-on: ubuntu-20.04
strategy:
fail-fast: false
matrix:
python: ['3.11', '3.12']
steps:
- name: Checkout the Git repository
uses: actions/checkout@v3
- name: Setup Python
uses: actions/setup-python@v4
with:
python-version: '3.11'
python-version: ${{ matrix.python }}
cache: 'pip'
- name: Check formatting
run: make format
lint:
name: Check for erroneous constructs
runs-on: ubuntu-20.04
strategy:
fail-fast: false
matrix:
python: ['3.11', '3.12']
steps:
- name: Checkout the Git repository
uses: actions/checkout@v3
- name: Setup Python
uses: actions/setup-python@v4
with:
python-version: '3.11'
python-version: ${{ matrix.python }}
cache: 'pip'
- name: Check for erroneous constructs
run: make lint
Expand All @@ -48,7 +56,7 @@ jobs:
strategy:
fail-fast: false
matrix:
python: ['3.11']
python: ['3.11', '3.12']
steps:
- name: Checkout the Git repository
uses: actions/checkout@v3
Expand All @@ -69,7 +77,7 @@ jobs:
- name: Setup Python
uses: actions/setup-python@v4
with:
python-version: '3.11'
python-version: '3.12'
cache: 'pip'
- name: Nuitka cache
uses: actions/cache@v3
Expand Down
2 changes: 1 addition & 1 deletion toltec/hooks/patch_rm2fb.py
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ def post_build( # pylint: disable=too-many-locals
# Search for binary objects that can be stripped
binaries = []

def filter_elfs(info: ELFFile) -> None:
def filter_elfs(info: ELFFile, file_path: str) -> None:
symtab = info.get_section_by_name(".symtab")
if symtab is None or info.get_machine_arch() != "ARM":
return
Expand Down
4 changes: 2 additions & 2 deletions toltec/hooks/strip.py
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ def walk_elfs(src_dir: str, for_each: Callable) -> None:

try:
with open(file_path, "rb") as file:
for_each(ELFFile(file))
for_each(ELFFile(file), file_path)
except ELFError:
# Ignore non-ELF files
pass
Expand Down Expand Up @@ -74,7 +74,7 @@ def post_build( # pylint: disable=too-many-locals,too-many-branches
strip_arm: List[str] = []
strip_x86: List[str] = []

def filter_elfs(info: ELFFile) -> None:
def filter_elfs(info: ELFFile, file_path: str) -> None:
symtab = info.get_section_by_name(".symtab")
if not symtab:
return
Expand Down

0 comments on commit 043a608

Please sign in to comment.