raise custom exception for unknown types