def getAllReceivers( sender = Any, signal = Any ):
    """Get list of all receivers from global tables

    This gets all receivers which should receive
    the given signal from sender, each receiver should
    be produced only once by the resulting generator
    """
    receivers = {}
    for set in (
        # Get receivers that receive *this* signal from *this* sender.
        getReceivers( sender, signal ),
        # Add receivers that receive *any* signal from *this* sender.
        getReceivers( sender, Any ),
        # Add receivers that receive *this* signal from *any* sender.
        getReceivers( Any, signal ),
        # Add receivers that receive *any* signal from *any* sender.
        getReceivers( Any, Any ),
    ):
        for receiver in set:
            if receiver: # filter out dead instance-method weakrefs
                try:
                    if receiver not in receivers:
                        receivers[receiver] = 1
                        yield receiver
                except TypeError:
                    # dead weakrefs raise TypeError on hash...
                    pass
Get list of all receivers from global tables

    This gets all receivers which should receive
    the given signal from sender, each receiver should
    be produced only once by the resulting generator