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

"TypeError: expected string or buffer" when Validation Options are set in config file but not provided in the resource field #48

Open
Civity-NL opened this issue Oct 15, 2019 · 0 comments

Comments

@Civity-NL
Copy link

Overview

As explained in the Documentation I set up a default value for the validation options in the configuration file.

I try to add a resource not providing any input in the resource field for validation options, and this leads to a Server error.

image

The Server error is "TypeError: expected string or buffer" generated from the following line of code.

So this should take into account the case where the value is null.

I've added this as a solution:

`

 if value:

      provided_options = json.loads(value)

      default_options.update(provided_options)

`

This should solve the issue. Should I submit a PR?


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

@roll roll added this to Software (broad) in Frictionless General Oct 21, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
No open projects
Frictionless General
  
Software (wide)
Development

No branches or pull requests

1 participant