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

error: {'status': 'ERROR', 'message': 'Error parsing Json: incorrect typeClass for field kindOfData, should be controlledVocabulary'} #153

Open
TutasiCSUC opened this issue Oct 27, 2022 · 2 comments
Labels
status:incoming Newly created issue to be forwarded

Comments

@TutasiCSUC
Copy link

Hi, recently our institution updated Dataverse Version to '5.11.1'.
Previously, the metadata Kind of Data wasn't mandatory for our institution, but now it is, and it appears with and dropdow with some options.

I am trying to create a dataset with Pydataverse with this code:

from pyDataverse.models import Dataset
ds = Dataset()
ds_filename = "dataset.json"
ds.from_json(read_file(ds_filename))
ds.validate_json()
resp = api.create_dataset("pyDataverse_user-guide", ds.json())
resp.json()

But i got this error: {'status': 'ERROR', 'message': 'Error parsing Json: incorrect typeClass for field kindOfData, should be controlledVocabulary'}

I attached the json I am using

@TutasiCSUC TutasiCSUC added the status:incoming Newly created issue to be forwarded label Oct 27, 2022
@qqmyers
Copy link
Member

qqmyers commented Oct 28, 2022

FWIW: kindOfData is not a controlled vocabulary value in the v5.11.1 release. It may be that your institution has changed the citation metadatablock to make kindOfData controlled. AFAIK, pyDataverse doesn't support such changes currently.

@skasberger
Copy link
Member

AFAIK, pyDataverse doesn't support such changes currently.
Not out of the box, but this can be easily adapted by adding/changing/removing the variables in the models module.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
status:incoming Newly created issue to be forwarded
Projects
None yet
Development

No branches or pull requests

3 participants