OpenDataServices / flatten-tool

Tools for generating CSV and other flat versions of the structured data
http://flatten-tool.readthedocs.io/en/latest/
MIT License
105 stars 15 forks source link

Remove restriction on CSV filename length #428

Closed duncandewhurst closed 1 year ago

duncandewhurst commented 1 year ago

Previously, CSV filenames were truncated to 31 characters, which is the maximum length of a sheet name in Excel. This PR allows CSV filenames of any length and only truncates sheet names when the output format is XLSX or ODS.

odscjames commented 1 year ago

I added changelog.

Also, I noticed while doing so this doesn't take account of the --sheet-prefix option - minor change needed there.

But I noticed when doing that --sheet-prefix was broken in ODS anyway, so I fixed that at the same time.

I don't know if I can do meaningful tests here, as I think all our tests run on CSV output?

jpmckinney commented 1 year ago

FYI, I don't think ODS (LibreOffice) is limited to 31 characters – though it's hard to find the actual number (OpenOffice.org seems to have used an in-app limit of 28).

odscjames commented 1 year ago

Thanks - I'll put that in an issue for later. This release leaves the ODS behaviour unchanged, so I think it's still good to go.