rambleraptor commented on code in PR #3305:
URL: https://github.com/apache/iceberg-python/pull/3305#discussion_r3175505979


##########
tests/catalog/test_hive.py:
##########
@@ -226,21 +226,18 @@ def run(self) -> None:
                     client.write(self._response)
                     client.flush()
             except Exception:
-                pass
+                break
 
     @property
     def port(self) -> int | None:
         self._port_bound.wait()
         return self._port
 
     def close(self) -> None:
-        # Close all client connections first
-        for client in self._clients:
-            try:
-                client.close()
-            except Exception:
-                pass
         self._socket.close()
+        self.join(timeout=5)
+        for client in self._clients:
+            client.close()

Review Comment:
   This should probably be in a try/except block again. If one of these throws 
an exception, it'll crash.



##########
tests/catalog/test_hive.py:
##########
@@ -226,21 +226,18 @@ def run(self) -> None:
                     client.write(self._response)
                     client.flush()
             except Exception:
-                pass
+                break
 
     @property
     def port(self) -> int | None:
         self._port_bound.wait()
         return self._port
 
     def close(self) -> None:
-        # Close all client connections first
-        for client in self._clients:
-            try:
-                client.close()
-            except Exception:
-                pass
         self._socket.close()
+        self.join(timeout=5)

Review Comment:
   I have the feeling I know the answer, but why 5?



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to