<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def getCSVReader(data, reader_type=csv.DictReader):
 """Take a Rave CSV output ending with a line with just EOF on it and return a DictReader"""

        f = StringIO(data[:-4])  # Remove \nEOF
        return reader_type(f)