"""Generic error messages.""" AUTHORIZATION_MSG = ( 'Account_id and account_type should be present ' 'either as headers or request parameters') FORBIDDEN_USER_MSG = 'User is forbidden' INCOMPLETE_GRASS_HEADERS_MSG = 'Incomplete Grass Headers' INVALID_TERRITORIES_MSG = ( 'Provided territories do not match existing ones for given ISRC') INVALID_CONTENT_TYPE_MSG = 'Content-Type should be application/json' INVALID_DATE_MSG = 'Date is expected to be in YYYY-MM-DD format' INVALID_GRASS_ACCOUNT_ID_MSG = 'Invalid Grass Account Id' INVALID_GRASS_ACCOUNT_TYPE_MSG = 'Invalid Grass Account Type' MISSING_GRASS_HEADERS_MSG = 'Missing Grass Headers' INVALID_GRASS_USER_ID_MSG = 'Invalid Orchard User Id' INVALID_PAGE_LIMIT_MSG = 'Page limit should be >= 1' INVALID_PAGE_OFFSET_MSG = 'Page offset should be >= 0' INVALID_SORT_BY_MSG = ( "'{input}' is an invalid column to sort. Available columns: {choices}") INVALID_SORT_ORDER_MSG = "Sort order can be either 'asc' or 'desc'" MISSING_HEADER_MSG = "Header '{}' is required" INVALID_FILTER_FIELD_MSG = 'Invalid filtering field, {}' NO_MATCHING_IDS_MSG = "No matching _id\'s found in Elasticsearch query" ID_COUNT_MISMATCH_MSG = "Not all _id\'s present in Elasticsearch query" ERROR_CODE_AUTHORIZATION = 'authorization_error' ERROR_CODE_BAD_REQUEST = 'bad_request' ERROR_CODE_BAD_GRASS_REQUEST = 'bad_grass_request_error' ERROR_CODE_BAD_QUERY_PARAM = 'bad_query_param_value' ERROR_CODE_BAD_GATEWAY = 'bad_gateway' ERROR_CODE_INVALID_HEADER = 'invalid_header_error' ERROR_CODE_MISSING_HEADER = 'missing_header_error' ERROR_CODE_NOT_FOUND = 'not_found' ERROR_CODE_VALIDATION = 'validation_error' SUCCESS_CODE = 'ok' INVALID_GROUPED_ID_FORMAT = ( 'Grouped conflicts id is expected to be in ' 'TUID|CONFLICT_DATE|CONFLICTING_OWNER|ACTION format') INVALID_GROUPED_ID = 'Grouped conflicts id is incorrect' BULK_ACTION_PAYLOAD_IS_TOO_LARGE = ( 'Number of actions in the payload is ' 'greater than the number of conflicts existing in database')