On Friday, February 21st, 2025 at 5:19 PM, open...@systemfailure.net wrote:
> On Friday, February 21st, 2025 at 11:15 AM, Stuart Henderson > s...@spacehopper.org wrote: > > > On 2025/02/21 10:13, open...@systemfailure.net wrote: > > > > > Hello, > > > > > > Here's an update for net/py3-rns (patch attached). Version 0.9.2 is a > > > maintenance release, fixing several bugs: > > > https://github.com/markqvist/Reticulum/releases/tag/0.9.2 > > > > > > I included a very simple patch for 'make test' to run (since 'make test' > > > was calling 'python' instead of 'python3'). All tests are passing except > > > one (error message also attached). I'm not able yet to understand why, > > > but oddly enough this test case fails on -current and passes on -stable. > > > The port seems to run fine anyway, both on -current and -stable (tested > > > on amd64). > > > > please add this rather than patching > > > > pre-test: > > ln -s ${MODPY_BIN} ${WRKDIR}/bin/python > > > > OK, here's a corrected version (see attachment). I didn't know the proper way > to solve this issue, still learning 😅 > > The same test case still fails on -current, and succeeds on -stable, by the > way. Oops, I forgot that on -stable, I had a symlink from '/usr/local/bin/python' to '/usr/local/bin/python3'. After removing this symlink, the same test case fails also on -stable, like on -current. So I reran 'make test' on -current, with this symlink, and the test is passing! Since the port itself seems to run just fine anyway, it is safe to assume that the failure results from the way unit tests are implemented, not from a real problem, and that it can just be ignored. My bad, sorry for the noise. > > > =================================== FAILURES > > > =================================== > > > __________________ TestChannel.test_send_receive_message_test > > > __________________ > > > > > > self = <tests.channel.TestChannel > > > testMethod=test_send_receive_message_test> > > > > > > def test_send_receive_message_test(self): > > > print("Channel test send and receive message") > > > message = MessageTest() > > > > > > def check(rx_message: MessageBase): > > > self.assertIsInstance(rx_message, message.class) > > > self.assertEqual(message.id, rx_message.id) > > > self.assertEqual(message.data, rx_message.data) > > > self.assertNotEqual(message.not_serialized, rx_message.not_serialized) > > > > > > > self.eat_own_dog_food(message, check) > > > > > > tests/channel.py:384: > > > _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ > > > _ _ _ > > > tests/channel.py:339: in eat_own_dog_food > > > self.assertEqual(1, envelope.tries) > > > E AssertionError: 1 != 2 > > > ----------------------------- Captured stdout call > > > ----------------------------- > > > > > > Channel test send and receive message > > > =========================== short test summary info > > > ============================ > > > FAILED tests/all.py::TestChannel::test_send_receive_message_test - > > > AssertionE... > > > =================== 1 failed, 32 passed, 1 skipped in 53.66s > > > =================== > > > *** Error 1 in . (/usr/ports/lang/python/python.port.mk:397 'do-test': @ > > > cd /usr/ports/pobj/py-rns-0.9.2/rns-0.9.2 && /usr/bin/env -i CC=cc ...) > > > *** Error 2 in . (/usr/ports/infrastructure/mk/bsd.port.mk:3098 > > > '/usr/ports/pobj/py-rns-0.9.2/.test_done': @cd /usr/ports/net/py-rns && > > > exec...) > > > *** Error 2 in /usr/ports/net/py-rns > > > (/usr/ports/infrastructure/mk/bsd.port.mk:2712 'test': > > > @lock=py3-rns-0.9.2; export _LOCKS_HELD=" py3-r...)