Menu

#283 QUTest 6.9.1. broken

QTOOLS
closed
1
2024-08-01
2020-10-20
Anonymous
No

With the changes introduced to the latest (6.9.1) version of QTools, the QUTest was broken. The symptoms are a "disability to connect to localhost". It was observed on a Docker image of a Linux (Ubuntu 18.04) machnie.

This can be solved in the qutest.py file with the following changes.

@@ -1066,7 +1066,7 @@ class QSpy:
        #bufsize = QSpy._sock.getsockopt(socket.SOL_UDP, socket.SO_RCVBUF)
        #print("SO_RCVBUF ", bufsize)
        try:
-   QSpy._sock.bind(("localhost", QSpy._local_port))
+   QSpy._sock.bind(("0.0.0.0", QSpy._local_port))
            #print("bind: ", ("localhost", QSpy._local_port))
        except:
            messagebox.showerror("UDP Socket Error",

@@ -1274,14 +1274,14 @@ def main(*args):
            QUTest._host_exe = ""
            QUTest._is_debug = True
    if arg < argc:
-  host_port = new_argv[arg].split(":")
+  host_port = argv[arg].split(":")
        arg += 1
        if len(host_port) > 0:
            QSpy._host_addr[0] = host_port[0]
        if len(host_port) > 1:
            QSpy._host_addr[1] = int(host_port[1])
    if arg < argc:
-  QSpy._tcp_port = new_argv[arg]
+  QSpy._tcp_port = argv[arg]

    QSpy._host_addr = tuple(QSpy._host_addr) # convert to immutable tuple

Discussion

  • Quantum Leaps

    Quantum Leaps - 2020-10-20

    Thanks for reporting.

    The problem has been fixed in the qtools git repos on GitHub and SourceForge.

    Also, the qutest and qview direct downloads on PyPi have been updated as well.

    Please update your qtools installation from whichever source you prefer.

    This bug affects only remote testing with QUTest, where the test scripts run on a different machine than QSpy. The bug fix will be officially included in the next QP-bundle release.

    --MMS

     
    👍
    1

    Last edit: Quantum Leaps 2020-10-20
  • Quantum Leaps

    Quantum Leaps - 2021-01-28
    • status: accepted --> closed
     
  • Quantum Leaps

    Quantum Leaps - 2021-01-28

    Fixed in QTools 6.9.2.
    --MMS

     

Anonymous
Anonymous

Add attachments
Cancel