Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Flexible column counts #176

Open
wants to merge 4 commits into
base: main
Choose a base branch
from

Conversation

oneElectron
Copy link

Fixes: #134

First off, I like and use the project a lot.
For me its a tool to see data better.
Therefore it seems a bit odd that tv doesn't just steamroll over malformed data.
It's tool for me to visualize data, it should try as much as possible to display whatever useful information it has, even if i made a mistake.

TODO

  • Write test(s)
  • Decide on default behavior
  • All a 'strict' mode that blocks any malformed csv file from displaying

What I did

The csv crate has a flexible mode. If the user did not request for either pedantic mode or jump-invalid-rows, then the code defaults to using flexible mode.
Pedantic mode parses as it did before I put my hands on it.
jump-invalid-rows skips over any row that returned an error when parsing with flexible = false.

@alexhallam
Copy link
Owner

@oneElectron. Thanks so much for the PR!

@alexhallam
Copy link
Owner

Once a test is added I will merge. I am happy you like tv, thanks for making it better!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Catch UnequalLengths
2 participants