xlsx2csv
xlsx2csv copied to clipboard
Indexing for sheets start at 1 instead of 0
Python arrays start at 0, so it is a bit confusing having to read indexes starting at 1. I know that 0 is meant to read all sheets, but in fact it is more intuitive to use None which is compatible with pandas definitions, for example.
Do you think this is generally a good idea or the current format is enough?
He had some quick discussion here https://github.com/pola-rs/polars/pull/6183 when trying to implement xlsx2csv and openpyxl together in the same API.
It seems like a good idea, but I don't see any way of changing it. People are using it already. Or, if you are using it from inside python, we can create a new version with breaking changes, where only python interface changes, and cmd interface doesn't change.
One argument against this is that Excel itself defaults to Sheet1
as the default first sheet:
It's awkward to have Sheet 1 be index 0, Sheet 2 be index 1, etc.