Skip to content

Rework "Fix race condition bugs" to fix pytest failure - #71

Open
uncoldice wants to merge 1 commit into
juergenH87:masterfrom
uncoldice:fix_pytest_failure
Open

Rework "Fix race condition bugs" to fix pytest failure#71
uncoldice wants to merge 1 commit into
juergenH87:masterfrom
uncoldice:fix_pytest_failure

Conversation

@uncoldice

@uncoldice uncoldice commented Jan 30, 2024

Copy link
Copy Markdown
Contributor

This is a rework of #42, which brought in some CI failures.

RaulSMS pushed a commit to kellergoech/python-can-j1939 that referenced this pull request Aug 19, 2026
Addresses review feedback on juergenH87#71 (both Copilot and khauersp) requesting
a regression test for the fix.

test_add_notifier_after_notifier_stop_still_delivers reproduces the exact
sequence: add a notifier, stop it (setting listener.stopped=True via
can.Notifier.stop()), remove it, then add a brand new notifier and
assert a real frame sent on the bus is actually delivered to a
subscriber. Verified this fails without the fix (reverted
electronic_control_unit.py locally, confirmed the test catches the
regression with "Frame was not delivered...") and passes with it.
RaulSMS pushed a commit to kellergoech/python-can-j1939 that referenced this pull request Aug 19, 2026
…er-stopped-flag

fix: reset MessageListener.stopped when re-adding to a notifier
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant