def get_liveaction_by_id(liveaction_id):
    """
    Get LiveAction by id.

    On error, raise ST2DBObjectNotFoundError.
    """
    liveaction = None

    try:
        liveaction = LiveAction.get_by_id(liveaction_id)
    except (ValidationError, ValueError) as e:
        LOG.error(
            'Database lookup for LiveAction with id="%s" resulted in ' "exception: %s",
            liveaction_id,
            e,
        )
        raise StackStormDBObjectNotFoundError(
            "Unable to find LiveAction with " 'id="%s"' % liveaction_id
        )

    return liveaction

    Get LiveAction by id.

    On error, raise ST2DBObjectNotFoundError.
    
st2common/st2common/util/action_db.py