nulib / arch

Northwestern University institutional repository, built on Samvera's Hyrax gem.
2 stars 0 forks source link

Catalog Sorting Displays "You are not authorized..." message #792

Closed chrisdaaz closed 2 years ago

chrisdaaz commented 2 years ago

Severity

Is the production site running?

Are staff blocked from performing their work?

Expected behavior

Users should be able to sort the catalog ("Browse") page without seeing warning/ error messages.

Actual behavior

image

Steps to reproduce the behavior

  1. Visit Arch staging, not logged in
  2. Visit the catalog page: https://arch.stack.rdc-staging.library.northwestern.edu/catalog?locale=en
  3. Change "Sort by relevance" to any of the other options.

Related work

Possibly but probably not related to #791

Done looks like

adamjarling commented 2 years ago

@bmquinn Don't work on this issue, you're spared.

adamjarling commented 2 years ago

@chrisdaaz Is this Staging and Production, or just Staging?

chrisdaaz commented 2 years ago

@adamjarling just staging

kdid commented 2 years ago

Hi @chrisdaaz - I looked into this. It's not necessarily a staging problem. It's happening when search results contain the thumbnail for a file set where the work is public but the file set itself is Northwestern or private. The not authorized message will also appear on the work page itself. If you change the file set to public, the message disappears.

I'm trying to determine if this is a Hyrax bug or expected behavior. Let me know if you know....

Is this a condition that happens a lot with real data on prod? (public work, Northwestern or private file sets for the representative file set)

kdid commented 2 years ago

@chrisdaaz - I apologize, so this is related to the work Brendan did recently. Sorry, I'm a bit out of the loop.

kdid commented 2 years ago

I just tested this on Nurax (3.3.0) and it looks like in this case the thumbnail shows as a broken link but there is no unauthorized message. So maybe that was ditched between v2 and v3.

Screen Shot 2022-03-15 at 4 30 29 PM Screen Shot 2022-03-15 at 4 29 39 PM
chrisdaaz commented 2 years ago

@kdid that makes sense! thank you for looking into it. @bmquinn and i have been thinking through how to make works that available to Northwestern users discoverable via Google and NUsearch (i.e. how most people find works in Arch).

"Work = Public / Fileset = Northwestern" is a condition we are experimenting with for dissertations, where authors allow their works to be downloaded by authenticated Northwestern users, but not the public. the problem is that Northwestern users would never know about the existence of the works because the Work records are hidden from public view (users would have to login to Arch and do a search before accessing a potentially useful dissertation, which is not how arch is being used).

would it be feasible to suppress that message on the /catalog view? it seems that's what's happened since Hyrax 3.3 has been released. if that's a messy task, and there's a plan to upgrade Arch to Hyrax 3.x, this issue can probably wait.

kdid commented 2 years ago

@chrisdaaz - Yeah, let me try to figure out how easy suppressing this message would be.

kdid commented 2 years ago

@chrisdaaz - I just merged a PR that should fix this but staging is down for some maintenance. I will let you know when it's back up.

kdid commented 2 years ago

@chrisdaaz - Staging looks to be back online now

chrisdaaz commented 2 years ago

looks great! thanks for adding a generic file icon and not a broken icon :)