hyrax icon indicating copy to clipboard operation
hyrax copied to clipboard

Upload new version of file: problem processing request

Open bbpennel opened this issue 1 year ago • 2 comments

Descriptive summary

We are encountering a confusing behavior when attempting to upload new versions of files in hyrax 3

  1. Go to a work page
  2. In the "Items" table, click "Select an action" > Versions
  3. Click "Upload new version"
  4. Get error "There was a problem processing your request.", which comes from a POST request returning HTTP status 422

Apparently the "Upload new version" button is the submit button for a form and is active by default. The "Choose new file version" button above it is how you select what file to upload, but this was unclear to users and the application allows "Upload new version" to be clicked before the action is valid.

I was able to produce this behavior in nurax with hyrax 3.5 and 4.

Rationale

We've had multiple people (who are experienced hyrax users) at our institution very confused by this behavior

Expected behavior

Either hide or disable the "Upload new version" button until a file has been selected with the "Choose new file version" button.

Actual behavior

"Upload new version" button active before selecting a file, and gives an ambiguous error message.

bbpennel avatar Apr 13 '23 19:04 bbpennel

This was discussed at the 5/10/2023 Hyrax Interest Group call. The group would like to proceed with the suggestion to make the "Upload new version" button inactive until a file has been selected.

Additionally, we'd like to move the "Choose new file version" button so that it is between the "Upload New Version" header and the "Upload new version" button.

rjkati avatar May 10 '23 16:05 rjkati

Verified that this is still possible/happening in Hyrax 5.0.0 using this work: https://dev.nurax.samvera.org/concern/images/ww72bb76t?locale=en

jlhardes avatar Mar 18 '24 20:03 jlhardes