Skip to content
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
25 changes: 20 additions & 5 deletions .github/workflows/CI.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,21 +22,36 @@

# A workflow run is made up of one or more jobs that can run sequentially or in parallel
jobs:
# This workflow contains a single job called "test"
lint:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4.2.2

- uses: actions/setup-python@v5.3.0
with:
python-version: '3.10'

- name: Install vermin
run: pip install vermin

- name: Check minimum Python version (must not exceed 3.10)
run: vermin --target=3.10- --backport enum j1939/

test:

Check warning

Code scanning / CodeQL

Workflow does not contain permissions Medium

Actions job or workflow does not limit the permissions of the GITHUB_TOKEN. Consider setting an explicit permissions block, using the following as a minimal starting point: {contents: read}
# The type of runner that the job will run on
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [ubuntu-latest, macos-latest, windows-latest]
python-version: ['3.10', '3.11', '3.12', '3.13']

steps:
# Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it
- uses: actions/setup-python@v4
- uses: actions/checkout@v4.2.2

- uses: actions/setup-python@v5.3.0
with:
python-version: '3.10'

- uses: actions/checkout@v2
python-version: ${{ matrix.python-version }}

- name: install dependencies
run: pip3 install -e .[test]
Expand Down
2 changes: 2 additions & 0 deletions README.rst
Original file line number Diff line number Diff line change
Expand Up @@ -80,6 +80,8 @@ Features
Installation
------------

Requires **Python 3.10 or later** and python-can_ >= 4.2.0.

Install can-j1939 with pip::

$ pip install can-j1939
Expand Down
5 changes: 5 additions & 0 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -18,10 +18,15 @@
long_description_content_type='text/x-rst',
license="MIT",
platforms=["any"],
python_requires=">=3.10",
classifiers=[
"License :: OSI Approved :: MIT License",
"Operating System :: OS Independent",
"Programming Language :: Python :: 3",
"Programming Language :: Python :: 3.10",
"Programming Language :: Python :: 3.11",
"Programming Language :: Python :: 3.12",
"Programming Language :: Python :: 3.13",
"Intended Audience :: Developers",
"Topic :: Scientific/Engineering"
],
Expand Down
10 changes: 5 additions & 5 deletions test/test_ca.py
Original file line number Diff line number Diff line change
Expand Up @@ -68,12 +68,12 @@ def test_addr_claim_fixed_reduced_time(feeder):
)
new_ca = feeder.ecu.add_ca(name=name, device_address=128)
new_ca.start(0.2)

# wait until all messages are processed asynchronously
# rounded up to account for scheduling delays
time.sleep(0.3)

# assert that the expected message was sent
# wait until the address claim message is processed, with a 2s timeout
deadline = time.monotonic() + 2.0
while len(feeder.can_messages) > 0 and time.monotonic() < deadline:
time.sleep(0.050)

assert len(feeder.can_messages) == 0


Expand Down
Loading