Changeset: a9121377e3dc for MonetDB
URL: https://dev.monetdb.org/hg/MonetDB/rev/a9121377e3dc
Modified Files:
        testing/Mtest.py.in
Branch: Mar2025
Log Message:

Flush output, catch timeout, give checkkeys connect more time.


diffs (46 lines):

diff --git a/testing/Mtest.py.in b/testing/Mtest.py.in
--- a/testing/Mtest.py.in
+++ b/testing/Mtest.py.in
@@ -1315,6 +1315,8 @@ def PerformDir(env, testdir, testlist, t
             print('\nInterrupted')
             interrupted = True
         finally:
+            sys.stdout.flush()
+            sys.stderr.flush()
             if pSrvr is not None:
                 pSrvr.sendusr1()
                 pSrvr.checkkeys()
@@ -2807,14 +2809,14 @@ class ServerClass:
         if not checkkeys:
             return
         self.outfile.flush()
-        with pymonetdb.connect(username='monetdb',
-                               password='monetdb',
-                               hostname=HOST,
-                               port=int(self.port),
-                               database=self.dbname,
-                               connect_timeout=1.0) as dbh:
-            dbh.settimeout(60)
-            try:
+        try:
+            with pymonetdb.connect(username='monetdb',
+                                   password='monetdb',
+                                   hostname=HOST,
+                                   port=int(self.port),
+                                   database=self.dbname,
+                                   connect_timeout=5.0) as dbh:
+                dbh.settimeout(60)
                 with dbh.cursor() as crs:
                     for table, columns in sys_pkeys + sys_akeys:
                         qtable = table.replace('"', '')
@@ -2841,8 +2843,8 @@ class ServerClass:
                         for row in rows:  # should be empty
                             print(f'missing reference in {qtable} {qcolumns}', 
row,
                                   query, file=self.outfile)
-            except TimeoutError:
-                pass
+        except TimeoutError:
+            print('timeout during checkkeys', file=self.outfile)
         self.outfile.flush()
 
     def stopsessions(self):
_______________________________________________
checkin-list mailing list -- [email protected]
To unsubscribe send an email to [email protected]

Reply via email to