Good discussion. Whether you can create your own CSV library easily or not, for non-developer RF users, and to save time & effort for others, it would be nice to have a prebuilt CSV library for use, perhaps built out of the Python CSV library mentioend by Guy.
Jakub, it's not clear what some of your current keywords do based on the name (perhaps not clear English). Here's some thoughts on improving the library with additional keywords/features:
* close CSV file?
* CSV write methods? to write a row or rows, or replace/overwrite a row or rows...
* library startup option or keyword to set CSV delimiter (comma, tab, space, etc. defaults to comma)
* library startup option to specify whether CSV file has header fields (default to no, if yes treat first row as header fields and 2nd row as first data row)
* or maybe in addition to library startup options above, those options could be specified in keyword that opens CSV file as well (as optional arguments with default values)
* get current cell/column number?
* get number of columns (in row)?
* get CSV header fields (as row/dictionary, always first row) - return null or empty list if library setting/parameter for CSV header is "no"
* get_cell_by_row_and_column_number(row_number,column_number)
* get_cell_by_row_number_and_column_name(row_number,column_name) 'column name = from CSV header field name
* get_cell_in_current_row_by_number(column_number)
* get_cell_in_current_row_by_column_name(column_name)
* go to first row (~rewind)
* go to last row?
* a keyword to return CSV data as 2d array (assuming can fit into memory, so that user can then manipulate as they see fit as Python object)
and when you get/return a row, what is the data type returned? List, tuple, dictionary? I forget the exact data types supported by Robot Framework, but it would be nice if you have the option to return a row in 2 formats:
cells mapped by index/column number {0: cell1value, 1: cell2value}
cells mapped by field name (in cases where CSV has header fields) {fieldname1: value, fieldname2: value}