def _get_arg(key, from_kwargs, default):
    """Remove value from kwargs and return it, else return default value"""
    if key in from_kwargs:
        arg = from_kwargs[key]
        del from_kwargs[key]
        return arg
    return default