swilson / aqualogic

A python library to interface with a Hayward/Goldline AquaLogic/ProLogic pool controller.
MIT License
40 stars 17 forks source link

Test failure #9

Open fabaff opened 3 years ago

fabaff commented 3 years ago

It seems that the tests are not terminating properly.

$ pytest
========================================================== test session starts ==========================================================
platform linux -- Python 3.9.5, pytest-6.2.4, py-1.10.0, pluggy-0.13.1
rootdir: /home/fab/Documents/repos/aqualogic
collected 2 items                                                                                                                       

tests/test_core.py .F                                                                                                             [100%]

=============================================================== FAILURES ================================================================
________________________________________________________ TestAquaLogic.test_spa _________________________________________________________

self = <tests.test_core.TestAquaLogic object at 0x7f086c5d04f0>

    def test_spa(self):
>       aq = AquaLogic()

tests/test_core.py:33: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
aqualogic/core.py:70: in __init__
    self._web.start(web_port)
aqualogic/web.py:37: in start
    self._loop.run_until_complete(runner.setup())
/usr/lib64/python3.9/asyncio/base_events.py:618: in run_until_complete
    self._check_running()
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <_UnixSelectorEventLoop running=True closed=False debug=False>

    def _check_running(self):
        if self.is_running():
>           raise RuntimeError('This event loop is already running')
E           RuntimeError: This event loop is already running

/usr/lib64/python3.9/asyncio/base_events.py:578: RuntimeError
======================================================== short test summary info ========================================================
FAILED tests/test_core.py::TestAquaLogic::test_spa - RuntimeError: This event loop is already running
====================================================== 1 failed, 1 passed in 0.84s ======================================================
^CException ignored in: <module 'threading' from '/usr/lib64/python3.9/threading.py'>
Traceback (most recent call last):
  File "/usr/lib64/python3.9/threading.py", line 1428, in _shutdown
    lock.acquire()
KeyboardInterrupt: 
sys:1: RuntimeWarning: coroutine 'BaseRunner.setup' was never awaited