Copilot commented on code in PR #51246:
URL: https://github.com/apache/arrow/pull/51246#discussion_r3978810906
##########
python/pyarrow/tests/test_io.py:
##########
@@ -1216,6 +1216,11 @@ def test_memory_map_resize(tmpdir):
assert f.read() == bytes(arr[:SIZE])
+def test_memory_map_resize_uninitialized():
+ with pytest.raises(ValueError, match="I/O operation on closed file"):
+ pa.MemoryMappedFile().resize(0)
+
+
Review Comment:
The PR description says this regression is exercised in a subprocess so a
crash is observable without taking down the pytest process, but this test
currently calls `pa.MemoryMappedFile().resize(0)` in-process. If the segfault
is reintroduced, the entire test run may abort rather than reporting a normal
test failure. Wrapping the call in a subprocess (as done in other tests that
expect signals) makes this a robust regression test.
--
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]