def is_valid_data_keyword(keyword):
    """
    Accepts a keyword submitted to the Document's "data" attribute and verifies
    that is is safe and not one of the reserved words DocumentCloud does not
    allow.

    Returns True is keyword is safe. Raises ValueError if it is not.

    See: https://github.com/documentcloud/documentcloud/blob/master/config/\
initializers/entity_map.rb#L22
    And: https://github.com/datadesk/python-documentcloud/issues/81
    """
    if RESERVED_KEYWORDS in keyword:
        raise ValueError("The key %s is reserved by DocumentCloud. \
You can't use it in 'data'" % keyword)
    else:
        return True
dataset/ETHPy150Open datadesk/python-documentcloud/documentcloud/__init__.py/is_valid_data_keyword/swapped operands of `in`