def _get_current_context(thread_id=None):
    """returns the current context during node evaluation"""
    if thread_id is None:
        thread_id = PyThread_get_thread_ident()
    try:
        ctx = _current_contexts[thread_id]
    except __HOLE__:
        ctx = None

    if ctx is None:
        raise NoCurrentContextError()
    return ctx
dataset/ETHPy150Open manahl/mdf/mdf/context.py/_get_current_context