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

universal viewer fails to display images #5556

Closed
elrayle opened this issue Mar 17, 2022 · 3 comments
Closed

universal viewer fails to display images #5556

elrayle opened this issue Mar 17, 2022 · 3 comments

Comments

@elrayle
Copy link
Contributor

elrayle commented Mar 17, 2022

Descriptive summary

Testing locally and on nurax-dev, the universal viewer on the work show page fails to display images.

Expected behavior

On the work show page, a generic work with an image displays the image in the universal viewer.

Actual behavior

On the work show page, a generic work with an image has the universal viewer, but it won't display the image.

on nurax-dev...

image

on localhost... there is a spinning icon instead of the "Your log-in attempt did not appear to be successful." message.

Log message...

Started GET "/images/kw52j805z%2Ffiles%2F08a44c10-bbf2-4dcc-ac7a-e59f2eba5421/info.json" for ::1 at 2022-03-17 16:23:50 -0400
Processing by Riiif::ImagesController#info as JSON
  Parameters: {"model"=>"riiif/image", "id"=>"kw52j805z/files/08a44c10-bbf2-4dcc-ac7a-e59f2eba5421"}
  Hyrax::Feature Load (0.2ms)  SELECT  "hyrax_features".* FROM "hyrax_features" WHERE "hyrax_features"."key" = $1 ORDER BY "hyrax_features"."id" ASC LIMIT $2  [["key", "read_only"], ["LIMIT", 1]] 
~/hyrax/app/controllers/concerns/hyrax/controller.rb:140
  User Load (0.2ms)  SELECT  "users".* FROM "users" WHERE "users"."id" = $1 ORDER BY "users"."id" ASC LIMIT $2  [["id", 1], ["LIMIT", 1]]
~/hyrax/app/services/hyrax/iiif_authorization_service.rb:11
Usergroups are ["public", "admin", "registered"]
  Hyrax::Feature Load (0.1ms)  SELECT  "hyrax_features".* FROM "hyrax_features" WHERE "hyrax_features"."key" = $1 ORDER BY "hyrax_features"."id" ASC LIMIT $2  [["key", "transfer_works"], ["LIMIT", 1]]
~/hyrax/app/models/concerns/hyrax/ability.rb:189
  Hyrax::Feature Load (0.1ms)  SELECT  "hyrax_features".* FROM "hyrax_features" WHERE "hyrax_features"."key" = $1 ORDER BY "hyrax_features"."id" ASC LIMIT $2  [["key", "proxy_deposit"], ["LIMIT", 1]]
~/hyrax/app/models/concerns/hyrax/ability.rb:195
Riiif resolved kw52j805z/files/08a44c10-bbf2-4dcc-ac7a-e59f2eba5421 to http://localhost:8984/rest/dev/kw/52/j8/05/kw52j805z/files/08a44c10-bbf2-4dcc-ac7a-e59f2eba5421
Riiif downloaded http://localhost:8984/rest/dev/kw/52/j8/05/kw52j805z/files/08a44c10-bbf2-4dcc-ac7a-e59f2eba5421 (9.5ms)
Completed 404 Not Found in 25ms (Views: 0.2ms | ActiveRecord: 0.6ms)

Steps to reproduce the behavior

  1. Navigate to: Dashboard -> Work
  2. Click button: Add new work
  3. Add required metadata
  4. Add an image file
  5. Save

This will forward to the work show page. Wait a few minutes for jobs to complete and refresh the page. The universal viewer will appear, but the image will not be shown in the viewer.

Related work

PR #5540
Issue #5504

@elrayle
Copy link
Contributor Author

elrayle commented Mar 17, 2022

I checked locally for the image file and the thumbnail. The image file uploaded to tmp/uploads/hyrax/uploaded_file/file/_A_NUMBER_/my_image.jpg.

I expected a thumbnail at tmp/derivatives based on Hyrax.config.derivatives_path. That directory doesn't exist.

>> Hyrax.config.derivatives_path
=> #<Pathname:..._hyrax_app_/tmp/derivatives>

@elrayle
Copy link
Contributor Author

elrayle commented Mar 17, 2022

When I added a child work that also has an image file to a work that already had an image, a 'thumbnail' (or at least a smaller version of the images) of each image appears in the sidebar of the viewer, but the main area that usually shows a large version of the images still shows the error message.

@elrayle
Copy link
Contributor Author

elrayle commented Mar 18, 2022

Ended up that fits was not properly configured on nurax-dev. Updated the ENV['FITS_PATH'] var to include the full path to fits and characterization started working again.

@elrayle elrayle closed this as completed Mar 18, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant