IQSS / IQSS/dataverse

Invalid CVocConf leads to 500 errors

Open
#10,631 12 comments 1 reaction 0 assignees View on GitHub

Nobody has claimed this yet.

Type: Bug
Dominant language
Java
Stars
1.1k
Forks
564
Avg merge
2d 2h
Merged PRs (30d)
29

Description

What steps does it take to reproduce the issue?

Change the CVocConf setting with

curl -X PUT --upload-file cvoc-conf.json http://localhost:8080/api/admin/settings/:CVocConf

  • When does this issue occur?

When updating the CVocConf settings
http://localhost:8080/api/admin/settings/:CVocConf

like explained in the guidelines:
curl -X PUT --upload-file cvoc-conf.json http://localhost:8080/api/admin/settings/:CVocConf

and an item in that json array is invalid (I guess it checks against the CVocConf.schema.json) the server stops working entirely redirecting to
500 - Internal Server Error - An unexpected error was encountered, no more information is available.

e.g. I removed the key: js-url

  • Which page(s) does it occurs on?

dataverse main/index page

  • What happens?

500 errors

  • To whom does it occur (all users, curators, superusers)?

  • What did you expect to happen?

The External Vocabulary script not running

Which version of Dataverse are you using?

v. 5.12.1 build 1122-cf90431

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Reproduce the PUT request to /api/admin/settings/:CVocConf using a CVocConf JSON array with the js-url key removed, then trace validation against CVocConf.schema.json and the resulting server error. Done means invalid settings produce a controlled response while the main/index page remains available and the external vocabulary script does not run.

Written by the indexing model from the issue text.

Assessment

Tech stack
java
Domain
api, backend
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
38/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.