def subscribe(ns, key, boxed):
    """Update ``ns[key]`` with the current value of a ``Boxed``."""
    setter = lambda val: setattr(ns, key, val)
    setter(boxed())
    boxed.changed.connect(setter)
