don't import plasma errors directly into top level pyarrow module

This commit is contained in:
Micah Kornfield committed 2019-07-02 21:44:52 -07:00
1 parent a66f999f85
commit 4d1ab8d1d6
2 files changed
+2 -7

No files matched your search

-5
View File
@@ -148,11 +148,6 @@ from pyarrow.ipc import (Message, MessageReader,
serialize_pandas, deserialize_pandas)
import pyarrow.ipc as ipc
try:
from pyarrow.plasma import PlasmaObjectExists, PlasmaStoreFull
except:
pass
def open_stream(source):
"""
+2 -2
View File
@@ -227,7 +227,7 @@ class TestPlasmaClient(object):
# Make sure that creating the same object twice raises an exception.
object_id = random_object_id()
self.plasma_client.create_and_seal(object_id, b'a', b'b')
with pytest.raises(pa.PlasmaObjectExists):
with pytest.raises(pa.plasma.PlasmaObjectExists):
self.plasma_client.create_and_seal(object_id, b'a', b'b')
# Make sure that these objects can be evicted.
@@ -852,7 +852,7 @@ class TestPlasmaClient(object):
for _ in range(2):
create_object(self.plasma_client2, DEFAULT_PLASMA_STORE_MEMORY, 0)
# Verify that an object that is too large does not fit.
with pytest.raises(pa.PlasmaStoreFull):
with pytest.raises(pa.plasma.PlasmaStoreFull):
create_object(self.plasma_client2,
DEFAULT_PLASMA_STORE_MEMORY + SMALL_OBJECT_SIZE, 0)