Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update Python versions: drop 3.8, add 3.13 to CI #114

Merged
merged 1 commit into from
Dec 10, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/host.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,11 +16,11 @@ jobs:
max-parallel: 5
matrix:
python-version:
- '3.8'
- '3.9'
- '3.10'
- '3.11'
- '3.12'
- '3.13'

name: test (${{ matrix.python-version }})
steps:
Expand Down
7 changes: 2 additions & 5 deletions apollo_fpga/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@
from .onboard_jtag import *

import importlib.metadata
import importlib.resources
__version__ = importlib.metadata.version(__package__)


Expand Down Expand Up @@ -168,11 +169,7 @@ def _init_backend(cls):
# In Windows, we need to specify the libusb library location to create a backend.
if platform.system() == "Windows":
# Determine the path to libusb-1.0.dll.
try:
from importlib_resources import files # <= 3.8
except:
from importlib.resources import files # >= 3.9
libusb_dll = os.path.join(files("usb1"), "libusb-1.0.dll")
libusb_dll = os.path.join(importlib.resources.files("usb1"), "libusb-1.0.dll")

# Create a backend by explicitly passing the path to libusb_dll.
cls.backend = usb.backend.libusb1.get_backend(find_library=lambda x: libusb_dll)
Expand Down
3 changes: 1 addition & 2 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ authors = [
license = { text = "BSD" }
description = "Python library and host tools for Apollo FPGA debug controllers."
readme = "README.md"
requires-python = ">=3.8"
requires-python = ">=3.9"
classifiers = [
'Programming Language :: Python',
'Development Status :: 5 - Production/Stable',
Expand All @@ -24,7 +24,6 @@ classifiers = [
'Topic :: Scientific/Engineering',
]
dependencies = [
"importlib_resources; python_version<'3.9'",
"pyusb>1.1.1",
"pyvcd>=0.2.4",
"prompt-toolkit>3.0.16",
Expand Down
Loading