Regression
OmeroWeb.test.integration.test_api_images.TestImages.test_dataset_images (from pytest)
Error Message
failed on setup with "AttributeError: 'numpy.ndarray' object has no attribute 'tostring'"
Stacktrace
self = <test_api_images.TestImages object at 0x7ff4d16a21d0> user1 = (<omero.clients.BaseClient object at 0x7ff4cc43c310>, object #0 (::omero::model::Experimenter) { _id = object #1 (...nnotationLinksSeq = { } _annotationLinksLoaded = False _annotationLinksCountPerOwner = { } }) @pytest.fixture() def dataset_images(self, user1): """Return Dataset with Images and an orphaned Image.""" dataset = DatasetI() dataset.name = rstring('Dataset') # Create 5 Images in Dataset for i in range(5): > img = self.create_test_image(size_x=125, size_y=125, session=user1[0].getSession(), name="Image%s" % i) test/integration/test_api_images.py:90: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ ../../../../.venv3/lib64/python3.11/site-packages/omero/testlib/__init__.py:445: in create_test_image script_utils.upload_plane(raw_pixel_store, plane_2d, _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ raw_pixels_store = d0b72f89-4007-4f96-a0a1-d43a3896d498/aaa047f1-8a6d-4e5c-8e8c-fcabda75e327omero.api.RawPixelsStore -t -e 1.1:tcp -h 172.18.0.11 -p 36999 -t 60000 plane = array([[ 0, 1, 2, ..., 122, 123, 124], [ 0, 1, 2, ..., 122, 123, 124], [ 0, 1, 2, ..., 12... [ 0, 1, 2, ..., 122, 123, 124], [ 0, 1, 2, ..., 122, 123, 124]], shape=(125, 125), dtype=int16) z = 0, c = 0, t = 0 def upload_plane(raw_pixels_store, plane, z, c, t): """ Upload the plane to the server attaching it to the current z,c,t of the already instantiated rawPixelStore. :param raw_pixels_store store pointing to the data. :param plane The data to upload :param z The Z-Section of the plane. :param c The C-Section of the plane. :param t The T-Section of the plane. """ byte_swapped_plane = plane.byteswap() > converted_plane = byte_swapped_plane.tostring() ^^^^^^^^^^^^^^^^^^^^^^^^^^^ E AttributeError: 'numpy.ndarray' object has no attribute 'tostring' ../../../../.venv3/lib64/python3.11/site-packages/omero/util/script_utils.py:1088: AttributeError