question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

A very bad CSV, that validate can not map

See original GitHub issue

Overview

Hi, I have this csv that has a lot of errors.

But, if I run

frictionless validate --buffer-size 250000 --sample-size 750 _11012018072326.csv 

I have only the error below, that blocks the real CSV validation check.

I have no info about the real source encoding, then I apply this solution: I run iconv -f utf-8 -t utf-8 -c input.csv >output.csv and then I use frictionless validate on the output.

I know, it’s not a real solution, but in this way I can map several useful CSV errors.

Is there a validate option, similar to the iconv one, to remove the unsupported character, and then to apply the validation to this cleaned input?

Thank you

===  =====  ==============  ============================================================================================================================
row  field  code            message
===  =====  ==============  ============================================================================================================================
            encoding-error  The data source could not be successfully decoded: 'utf-8' codec can't decode byte 0x8d in position 1447: invalid start byte
===  =====  ==============  ============================================================================================================================

Please preserve this line to notify @roll (lead of this repository)

Issue Analytics

  • State:closed
  • Created 2 years ago
  • Comments:6 (6 by maintainers)

github_iconTop GitHub Comments

1reaction
rollcommented, Oct 18, 2021

Ok. I see. I’ll investigate

0reactions
aborrusocommented, Oct 20, 2021

I’ve create a feature request for it - #932

Thank you very much!

Read more comments on GitHub >

github_iconTop Results From Across the Web

6 Common CSV Import Errors and How to Fix Them
Issues with data values can be a significant cause of CSV importing errors. These include unexpected data length – either too long or...
Read more >
Common CSV Template Error Messages and How to Fix ...
To fix this error, the uploaded CSV file must be fixed so as to be a valid UTF-8 CSV file. You should check...
Read more >
Generic errors from uploading and published CSV files as ...
In some instances, generic errors occur when CSV files are uploaded or published as hosted feature layers in ArcGIS Online or Portal for...
Read more >
No exception thrown if csv file has no record but header ...
I tried setting ThrowOnBadData to true, but it does not help the header fields get validated against the ClassMap. This can cause serious...
Read more >
Vroom/fread won't read LARGE .csv file - cannot memory ...
So fread cannot be used on its own in case your csv file is too big for your machine. Please correct me if...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found