samredai commented on a change in pull request #4021:
URL: https://github.com/apache/iceberg/pull/4021#discussion_r801118064



##########
File path: python/tests/io/test_base.py
##########
@@ -49,8 +49,11 @@ def __len__(self):
     def exists(self):
         return os.path.exists(self.parsed_location.path)
 
-    def open(self):
-        return open(self.parsed_location.path, "rb")
+    def open(self) -> InputStream:
+        input_file = open(self.parsed_location.path, "rb")
+        if not isinstance(input_file, InputStream):
+            raise RuntimeError("""Object returned from LocalInputFile.open 
does not match the OutputStream protocol.""")

Review comment:
       Updated




-- 
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