def __setitem__(self, n, obj):
        """
        Change the value of one contained objects, and resolve references if
        all objects have been referenced.
        """
        self.l[n] = obj
        if not isinstance(obj, NotKnown):
            self.locs.remove(n)
            if not self.locs:
                self.resolveDependants(self.containerType(self.l))

        Change the value of one contained objects, and resolve references if
        all objects have been referenced.
        
stackoverflow/venv/lib/python3.6/site-packages/twisted/persisted/crefutil.py