<classResult _class='hudson.tasks.junit.ClassResult'><child><age>0</age><className>OmeroPy.test.integration.gatewaytest.test_annotation</className><duration>1.603</duration><failedSince>0</failedSince><name>testAnnotationCount</name><properties></properties><skipped>false</skipped><status>PASSED</status></child><child><age>1</age><className>OmeroPy.test.integration.gatewaytest.test_annotation</className><duration>1.351</duration><errorDetails>KeyError: None</errorDetails><errorStackTrace>author_testimg_generated = &lt;_ImageWrapper id=5673&gt;

    def testBooleanAnnotation(author_testimg_generated):
&gt;       _testAnnotation(author_testimg_generated,
                        omero.gateway.BooleanAnnotationWrapper,
                        TESTANN_NS, True)

test/integration/gatewaytest/test_annotation.py:161: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

obj = &lt;_ImageWrapper id=5673&gt;
annclass = &lt;class 'omero.gateway.BooleanAnnotationWrapper'&gt;
ns = 'omero.gateway.test_annotation', value = True, sameOwner = False
testOwner = None

    def _testAnnotation(obj, annclass, ns, value, sameOwner=False,
                        testOwner=None):
        gateway = obj._conn
        # Make sure it doesn't yet exist
        obj.removeAnnotations(ns)
        assert obj.getAnnotation(ns) is None
        # Create new, link and check
        ann = annclass(gateway)
        ann.setNs(ns)
        ann.setValue(value)
        if sameOwner:
            obj.linkAnnotation(ann, sameOwner=True)
        else:
            # checks that default sameOwner=False
            obj.linkAnnotation(ann)
        ann = obj.getAnnotation(ns)
        # Make sure the group for the annotation is the same as the original
        # object. (#120)
        assert ann.getDetails().getGroup() == obj.getDetails().getGroup()
        tval = hasattr(value, 'val') and value.val or value
        assert ann.getValue() == value, '%s != %s' % (str(ann.getValue()),
                                                      str(tval))
        assert ann.getNs() == ns,  '%s != %s' % (str(ann.getNs()), str(ns))
        if testOwner is not None:
            testOwner(obj, ann)
        # test conn.countAnnotations()
        counts = gateway.countAnnotations(obj.OMERO_CLASS, [obj.id])
        assert counts is not None
        # Timestamp and Boolean not included in counts
        if annclass.OMERO_CLASS not in ["TimestampAnnotation",
                                        "BooleanAnnotation",
                                        # LongAnnotation is only for 'rating'
                                        "LongAnnotation"]:
&gt;           assert counts[annclass.OMERO_CLASS] &gt;= 1.   # e.g. TagAnnotation: 1
                   ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
E           KeyError: None

test/integration/gatewaytest/test_annotation.py:59: KeyError</errorStackTrace><failedSince>71</failedSince><name>testBooleanAnnotation</name><properties></properties><skipped>false</skipped><status>FAILED</status></child><child><age>1</age><className>OmeroPy.test.integration.gatewaytest.test_annotation</className><duration>1.526</duration><errorDetails>KeyError: None</errorDetails><errorStackTrace>author_testimg_generated = &lt;_ImageWrapper id=5671&gt;

    def testCommentAnnotation(author_testimg_generated):
&gt;       return _testAnnotation(author_testimg_generated,
                               omero.gateway.CommentAnnotationWrapper,
                               TESTANN_NS, 'some value')

test/integration/gatewaytest/test_annotation.py:115: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

obj = &lt;_ImageWrapper id=5671&gt;
annclass = &lt;class 'omero.gateway.CommentAnnotationWrapper'&gt;
ns = 'omero.gateway.test_annotation', value = 'some value', sameOwner = False
testOwner = None

    def _testAnnotation(obj, annclass, ns, value, sameOwner=False,
                        testOwner=None):
        gateway = obj._conn
        # Make sure it doesn't yet exist
        obj.removeAnnotations(ns)
        assert obj.getAnnotation(ns) is None
        # Create new, link and check
        ann = annclass(gateway)
        ann.setNs(ns)
        ann.setValue(value)
        if sameOwner:
            obj.linkAnnotation(ann, sameOwner=True)
        else:
            # checks that default sameOwner=False
            obj.linkAnnotation(ann)
        ann = obj.getAnnotation(ns)
        # Make sure the group for the annotation is the same as the original
        # object. (#120)
        assert ann.getDetails().getGroup() == obj.getDetails().getGroup()
        tval = hasattr(value, 'val') and value.val or value
        assert ann.getValue() == value, '%s != %s' % (str(ann.getValue()),
                                                      str(tval))
        assert ann.getNs() == ns,  '%s != %s' % (str(ann.getNs()), str(ns))
        if testOwner is not None:
            testOwner(obj, ann)
        # test conn.countAnnotations()
        counts = gateway.countAnnotations(obj.OMERO_CLASS, [obj.id])
        assert counts is not None
        # Timestamp and Boolean not included in counts
        if annclass.OMERO_CLASS not in ["TimestampAnnotation",
                                        "BooleanAnnotation",
                                        # LongAnnotation is only for 'rating'
                                        "LongAnnotation"]:
&gt;           assert counts[annclass.OMERO_CLASS] &gt;= 1.   # e.g. TagAnnotation: 1
                   ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
E           KeyError: None

test/integration/gatewaytest/test_annotation.py:59: KeyError</errorStackTrace><failedSince>71</failedSince><name>testCommentAnnotation</name><properties></properties><skipped>false</skipped><status>FAILED</status></child><child><age>0</age><className>OmeroPy.test.integration.gatewaytest.test_annotation</className><duration>2.134</duration><failedSince>0</failedSince><name>testDualLinkedAnnotation</name><properties></properties><skipped>false</skipped><status>PASSED</status></child><child><age>0</age><className>OmeroPy.test.integration.gatewaytest.test_annotation</className><duration>1.734</duration><failedSince>0</failedSince><name>testFileAnnNonDefaultGroup</name><properties></properties><skipped>false</skipped><status>PASSED</status></child><child><age>0</age><className>OmeroPy.test.integration.gatewaytest.test_annotation</className><duration>2.091</duration><failedSince>0</failedSince><name>testFileAnnotation</name><properties></properties><skipped>false</skipped><status>PASSED</status></child><child><age>0</age><className>OmeroPy.test.integration.gatewaytest.test_annotation</className><duration>1.694</duration><failedSince>0</failedSince><name>testFileAnnotationNoName</name><properties></properties><skipped>false</skipped><status>PASSED</status></child><child><age>0</age><className>OmeroPy.test.integration.gatewaytest.test_annotation</className><duration>3.255</duration><failedSince>0</failedSince><name>testFileAnnotationSpeed</name><properties></properties><skipped>false</skipped><status>PASSED</status></child><child><age>0</age><className>OmeroPy.test.integration.gatewaytest.test_annotation</className><duration>1.55</duration><failedSince>0</failedSince><name>testListAnnotations</name><properties></properties><skipped>false</skipped><status>PASSED</status></child><child><age>1</age><className>OmeroPy.test.integration.gatewaytest.test_annotation</className><duration>1.399</duration><errorDetails>KeyError: None</errorDetails><errorStackTrace>author_testimg_generated = &lt;_ImageWrapper id=5674&gt;

    def testLongAnnotation(author_testimg_generated):
&gt;       _testAnnotation(author_testimg_generated,
                        omero.gateway.LongAnnotationWrapper,
                        TESTANN_NS, int(1000))

test/integration/gatewaytest/test_annotation.py:167: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

obj = &lt;_ImageWrapper id=5674&gt;
annclass = &lt;class 'omero.gateway.LongAnnotationWrapper'&gt;
ns = 'omero.gateway.test_annotation', value = 1000, sameOwner = False
testOwner = None

    def _testAnnotation(obj, annclass, ns, value, sameOwner=False,
                        testOwner=None):
        gateway = obj._conn
        # Make sure it doesn't yet exist
        obj.removeAnnotations(ns)
        assert obj.getAnnotation(ns) is None
        # Create new, link and check
        ann = annclass(gateway)
        ann.setNs(ns)
        ann.setValue(value)
        if sameOwner:
            obj.linkAnnotation(ann, sameOwner=True)
        else:
            # checks that default sameOwner=False
            obj.linkAnnotation(ann)
        ann = obj.getAnnotation(ns)
        # Make sure the group for the annotation is the same as the original
        # object. (#120)
        assert ann.getDetails().getGroup() == obj.getDetails().getGroup()
        tval = hasattr(value, 'val') and value.val or value
        assert ann.getValue() == value, '%s != %s' % (str(ann.getValue()),
                                                      str(tval))
        assert ann.getNs() == ns,  '%s != %s' % (str(ann.getNs()), str(ns))
        if testOwner is not None:
            testOwner(obj, ann)
        # test conn.countAnnotations()
        counts = gateway.countAnnotations(obj.OMERO_CLASS, [obj.id])
        assert counts is not None
        # Timestamp and Boolean not included in counts
        if annclass.OMERO_CLASS not in ["TimestampAnnotation",
                                        "BooleanAnnotation",
                                        # LongAnnotation is only for 'rating'
                                        "LongAnnotation"]:
&gt;           assert counts[annclass.OMERO_CLASS] &gt;= 1.   # e.g. TagAnnotation: 1
                   ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
E           KeyError: None

test/integration/gatewaytest/test_annotation.py:59: KeyError</errorStackTrace><failedSince>71</failedSince><name>testLongAnnotation</name><properties></properties><skipped>false</skipped><status>FAILED</status></child><child><age>1</age><className>OmeroPy.test.integration.gatewaytest.test_annotation</className><duration>1.436</duration><errorDetails>KeyError: None</errorDetails><errorStackTrace>author_testimg_generated = &lt;_ImageWrapper id=5675&gt;

    def testMapAnnotation(author_testimg_generated):
        data = [("foo", "bar"),
                ("test key", "test value")]
&gt;       _testAnnotation(author_testimg_generated,
                        omero.gateway.MapAnnotationWrapper,
                        TESTANN_NS, data)

test/integration/gatewaytest/test_annotation.py:175: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

obj = &lt;_ImageWrapper id=5675&gt;
annclass = &lt;class 'omero.gateway.MapAnnotationWrapper'&gt;
ns = 'omero.gateway.test_annotation'
value = [('foo', 'bar'), ('test key', 'test value')], sameOwner = False
testOwner = None

    def _testAnnotation(obj, annclass, ns, value, sameOwner=False,
                        testOwner=None):
        gateway = obj._conn
        # Make sure it doesn't yet exist
        obj.removeAnnotations(ns)
        assert obj.getAnnotation(ns) is None
        # Create new, link and check
        ann = annclass(gateway)
        ann.setNs(ns)
        ann.setValue(value)
        if sameOwner:
            obj.linkAnnotation(ann, sameOwner=True)
        else:
            # checks that default sameOwner=False
            obj.linkAnnotation(ann)
        ann = obj.getAnnotation(ns)
        # Make sure the group for the annotation is the same as the original
        # object. (#120)
        assert ann.getDetails().getGroup() == obj.getDetails().getGroup()
        tval = hasattr(value, 'val') and value.val or value
        assert ann.getValue() == value, '%s != %s' % (str(ann.getValue()),
                                                      str(tval))
        assert ann.getNs() == ns,  '%s != %s' % (str(ann.getNs()), str(ns))
        if testOwner is not None:
            testOwner(obj, ann)
        # test conn.countAnnotations()
        counts = gateway.countAnnotations(obj.OMERO_CLASS, [obj.id])
        assert counts is not None
        # Timestamp and Boolean not included in counts
        if annclass.OMERO_CLASS not in ["TimestampAnnotation",
                                        "BooleanAnnotation",
                                        # LongAnnotation is only for 'rating'
                                        "LongAnnotation"]:
&gt;           assert counts[annclass.OMERO_CLASS] &gt;= 1.   # e.g. TagAnnotation: 1
                   ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
E           KeyError: None

test/integration/gatewaytest/test_annotation.py:59: KeyError</errorStackTrace><failedSince>71</failedSince><name>testMapAnnotation</name><properties></properties><skipped>false</skipped><status>FAILED</status></child><child><age>1</age><className>OmeroPy.test.integration.gatewaytest.test_annotation</className><duration>1.158</duration><errorDetails>KeyError: None</errorDetails><errorStackTrace>gatewaywrapper = &lt;omero.gateway.pytest_fixtures.GatewayWrapper object at 0x7f4731b36510&gt;

    def testNonDefGroupAnnotation(gatewaywrapper):
        p = gatewaywrapper.getTestProject2()
&gt;       return _testAnnotation(p,
                               omero.gateway.CommentAnnotationWrapper,
                               TESTANN_NS, 'some value')

test/integration/gatewaytest/test_annotation.py:122: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

obj = &lt;_ProjectWrapper id=491&gt;
annclass = &lt;class 'omero.gateway.CommentAnnotationWrapper'&gt;
ns = 'omero.gateway.test_annotation', value = 'some value', sameOwner = False
testOwner = None

    def _testAnnotation(obj, annclass, ns, value, sameOwner=False,
                        testOwner=None):
        gateway = obj._conn
        # Make sure it doesn't yet exist
        obj.removeAnnotations(ns)
        assert obj.getAnnotation(ns) is None
        # Create new, link and check
        ann = annclass(gateway)
        ann.setNs(ns)
        ann.setValue(value)
        if sameOwner:
            obj.linkAnnotation(ann, sameOwner=True)
        else:
            # checks that default sameOwner=False
            obj.linkAnnotation(ann)
        ann = obj.getAnnotation(ns)
        # Make sure the group for the annotation is the same as the original
        # object. (#120)
        assert ann.getDetails().getGroup() == obj.getDetails().getGroup()
        tval = hasattr(value, 'val') and value.val or value
        assert ann.getValue() == value, '%s != %s' % (str(ann.getValue()),
                                                      str(tval))
        assert ann.getNs() == ns,  '%s != %s' % (str(ann.getNs()), str(ns))
        if testOwner is not None:
            testOwner(obj, ann)
        # test conn.countAnnotations()
        counts = gateway.countAnnotations(obj.OMERO_CLASS, [obj.id])
        assert counts is not None
        # Timestamp and Boolean not included in counts
        if annclass.OMERO_CLASS not in ["TimestampAnnotation",
                                        "BooleanAnnotation",
                                        # LongAnnotation is only for 'rating'
                                        "LongAnnotation"]:
&gt;           assert counts[annclass.OMERO_CLASS] &gt;= 1.   # e.g. TagAnnotation: 1
                   ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
E           KeyError: None

test/integration/gatewaytest/test_annotation.py:59: KeyError</errorStackTrace><failedSince>71</failedSince><name>testNonDefGroupAnnotation</name><properties></properties><skipped>false</skipped><status>FAILED</status></child><child><age>1</age><className>OmeroPy.test.integration.gatewaytest.test_annotation</className><duration>3.605</duration><errorDetails>KeyError: None</errorDetails><errorStackTrace>gatewaywrapper = &lt;omero.gateway.pytest_fixtures.GatewayWrapper object at 0x7f46e7c60a50&gt;

    def testSameOwner(gatewaywrapper):
        """
            tests project.linkAnnotation(sameOwner=False)
            Tests sameOwner default is False (was True for 4.4.x but False in 5.0)
        """
        gatewaywrapper.loginAsAdmin()
    
        gatewaywrapper.gateway.SERVICE_OPTS.setOmeroGroup("-1")
        p = gatewaywrapper.getTestProject2()
        p.getDetails().owner.id.val
    
        def sameOwner(obj, ann):
            assert obj.getDetails().owner.id.val == ann.getDetails().owner.id.val
    
        def differentOwner(obj, ann):
            assert obj.getDetails().owner.id.val != ann.getDetails().owner.id.val
    
&gt;       _testAnnotation(p,
                        omero.gateway.CommentAnnotationWrapper,
                        TESTANN_NS, 'some value',
                        sameOwner=True, testOwner=sameOwner)

test/integration/gatewaytest/test_annotation.py:104: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

obj = &lt;_ProjectWrapper id=487&gt;
annclass = &lt;class 'omero.gateway.CommentAnnotationWrapper'&gt;
ns = 'omero.gateway.test_annotation', value = 'some value', sameOwner = True
testOwner = &lt;function testSameOwner.&lt;locals&gt;.sameOwner at 0x7f46fd0016c0&gt;

    def _testAnnotation(obj, annclass, ns, value, sameOwner=False,
                        testOwner=None):
        gateway = obj._conn
        # Make sure it doesn't yet exist
        obj.removeAnnotations(ns)
        assert obj.getAnnotation(ns) is None
        # Create new, link and check
        ann = annclass(gateway)
        ann.setNs(ns)
        ann.setValue(value)
        if sameOwner:
            obj.linkAnnotation(ann, sameOwner=True)
        else:
            # checks that default sameOwner=False
            obj.linkAnnotation(ann)
        ann = obj.getAnnotation(ns)
        # Make sure the group for the annotation is the same as the original
        # object. (#120)
        assert ann.getDetails().getGroup() == obj.getDetails().getGroup()
        tval = hasattr(value, 'val') and value.val or value
        assert ann.getValue() == value, '%s != %s' % (str(ann.getValue()),
                                                      str(tval))
        assert ann.getNs() == ns,  '%s != %s' % (str(ann.getNs()), str(ns))
        if testOwner is not None:
            testOwner(obj, ann)
        # test conn.countAnnotations()
        counts = gateway.countAnnotations(obj.OMERO_CLASS, [obj.id])
        assert counts is not None
        # Timestamp and Boolean not included in counts
        if annclass.OMERO_CLASS not in ["TimestampAnnotation",
                                        "BooleanAnnotation",
                                        # LongAnnotation is only for 'rating'
                                        "LongAnnotation"]:
&gt;           assert counts[annclass.OMERO_CLASS] &gt;= 1.   # e.g. TagAnnotation: 1
                   ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
E           KeyError: None

test/integration/gatewaytest/test_annotation.py:59: KeyError</errorStackTrace><failedSince>71</failedSince><name>testSameOwner</name><properties></properties><skipped>false</skipped><status>FAILED</status></child><child><age>1</age><className>OmeroPy.test.integration.gatewaytest.test_annotation</className><duration>1.353</duration><errorDetails>KeyError: None</errorDetails><errorStackTrace>author_testimg_generated = &lt;_ImageWrapper id=5672&gt;

    def testTimestampAnnotation(author_testimg_generated):
        now = time.time()
        t = datetime.datetime.fromtimestamp(int(now))
&gt;       _testAnnotation(author_testimg_generated,
                        omero.gateway.TimestampAnnotationWrapper,
                        TESTANN_NS, t)

test/integration/gatewaytest/test_annotation.py:130: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

obj = &lt;_ImageWrapper id=5672&gt;
annclass = &lt;class 'omero.gateway.TimestampAnnotationWrapper'&gt;
ns = 'omero.gateway.test_annotation'
value = datetime.datetime(2026, 8, 29, 4, 53, 44), sameOwner = False
testOwner = None

    def _testAnnotation(obj, annclass, ns, value, sameOwner=False,
                        testOwner=None):
        gateway = obj._conn
        # Make sure it doesn't yet exist
        obj.removeAnnotations(ns)
        assert obj.getAnnotation(ns) is None
        # Create new, link and check
        ann = annclass(gateway)
        ann.setNs(ns)
        ann.setValue(value)
        if sameOwner:
            obj.linkAnnotation(ann, sameOwner=True)
        else:
            # checks that default sameOwner=False
            obj.linkAnnotation(ann)
        ann = obj.getAnnotation(ns)
        # Make sure the group for the annotation is the same as the original
        # object. (#120)
        assert ann.getDetails().getGroup() == obj.getDetails().getGroup()
        tval = hasattr(value, 'val') and value.val or value
        assert ann.getValue() == value, '%s != %s' % (str(ann.getValue()),
                                                      str(tval))
        assert ann.getNs() == ns,  '%s != %s' % (str(ann.getNs()), str(ns))
        if testOwner is not None:
            testOwner(obj, ann)
        # test conn.countAnnotations()
        counts = gateway.countAnnotations(obj.OMERO_CLASS, [obj.id])
        assert counts is not None
        # Timestamp and Boolean not included in counts
        if annclass.OMERO_CLASS not in ["TimestampAnnotation",
                                        "BooleanAnnotation",
                                        # LongAnnotation is only for 'rating'
                                        "LongAnnotation"]:
&gt;           assert counts[annclass.OMERO_CLASS] &gt;= 1.   # e.g. TagAnnotation: 1
                   ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
E           KeyError: None

test/integration/gatewaytest/test_annotation.py:59: KeyError</errorStackTrace><failedSince>71</failedSince><name>testTimestampAnnotation</name><properties></properties><skipped>false</skipped><status>FAILED</status></child><child><age>0</age><className>OmeroPy.test.integration.gatewaytest.test_annotation</className><duration>1.412</duration><failedSince>0</failedSince><name>testUnlinkAnnotation</name><properties></properties><skipped>false</skipped><status>PASSED</status></child><failCount>7</failCount><name>test_annotation</name><passCount>8</passCount><skipCount>0</skipCount></classResult>