def get_hub():
    """Get the current event hub singleton object

    .. note :: |internal|
    """
    try:
        hub = _threadlocal.hub
    except __HOLE__:
        # instantiate a Hub
        try:
            _threadlocal.Hub
        except AttributeError:
            use_hub()

        hub = _threadlocal.hub = _threadlocal.Hub()
    return hub
dataset/ETHPy150Open veegee/guv/guv/hubs/hub.py/get_hub