Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
What's new
10
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Open sidebar
Validata
validata-ui
Commits
1cd04d93
Commit
1cd04d93
authored
Oct 01, 2018
by
Pierre Dittgen
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Wrong column delimiter becomes Invalid column delimiter
parent
42c66041
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
7 additions
and
2 deletions
+7
-2
validata_ui_next/views.py
validata_ui_next/views.py
+7
-2
No files found.
validata_ui_next/views.py
View file @
1cd04d93
...
...
@@ -70,7 +70,7 @@ ERR_CODE_TO_CONTEXT = dict([
(
'minimum-constraint'
,
'body'
),
# TODO: get it from validata_validate
(
'
wrong
-column-delimiter'
,
'table'
)
(
'
invalid
-column-delimiter'
,
'table'
)
# Custom checks fall in default case: body
])
...
...
@@ -121,6 +121,11 @@ def create_validata_report(goodtables_report):
rows
=
[]
current_row_id
=
0
for
err
in
report
[
'table'
][
'errors'
][
'body'
]:
if
not
'column-number'
in
err
:
# TODO: handle blank row
print
(
"No column-number problem"
,
err
)
continue
row_id
=
err
[
'row-number'
]
del
err
[
'row-number'
]
del
err
[
'context'
]
...
...
@@ -142,7 +147,7 @@ def validate(schema_code, source, source_type):
validata_report
=
create_validata_report
(
goodtables_report
)
# return jsonify(
better
_report)
# return jsonify(
validata
_report)
source_data
=
extract_source_data
(
source
)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment