ckan / ckan/ckanext-validation

Data Schema with characters incompatible with ascii

Open
#47 1 comment 0 reactions 0 assignees View on GitHub
Dominant language
Python
Stars
30
Forks
33
PR merge metrics
No merged PRs in 30d

Description

# Overview

The Data Schema JSON will throw an error if it includes characters not compatible with ascii.
This happens due to the use of Swedish characters like "Ö" and "Ä".

![validation](https://user-images.githubusercontent.com/31211012/66822489-9ea5ee80-ef44-11e9-9523-6c46faccf1cd.png)

This is the [line of code](https://github.com/frictionlessdata/ckanext-validation/blob/master/ckanext/validation/validators.py#L24) where it happens. I made a quick workaround by replacing it with:

`descriptor = json.loads(value.encode('utf-8'))`

Just wanted to get some feedback on how to approach this, if there should be somewhere an option to declare the encoding of the file? Or you want a PR with this work around?

---

Please preserve this line to notify @amercader (maintainer of this repository)

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.