wireservice / wireservice/csvkit
in2csv: Importing messy data
Nobody has claimed this yet.
- Dominant language
- Python
- Stars
- 6.4k
- Forks
- 689
- Avg merge
- 1m
- Merged PRs (30d)
- 1
Description
I have multiple spreadsheets with a few metadata rows before the actual data. This trips up csvkit's automatic header detection. I'm processing them in bulk, so I can't rely on pre-counting the number of metadata lines for each.
In particular, this means that in2csv's behaviour where it automatically fills in the first line expecting it to be the header is counterproductive here -- I'm forced to invoke it as in2csv -H | tail -n+2.
Can in2csv be given an --ignore-missing-headers option or somesuch? I'll be piping it into xan or miller for further cleanup, so I don't need a cleverer handling method than that.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start at the in2csv command entry point and trace its automatic header-detection path. Implement and document the requested option so spreadsheets with leading metadata rows can be processed in bulk without pre-counting them, then verify the resulting command-line behavior described in the issue.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- python
- Domain
- cli, data
- Issue type
- Feature
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 45/100