uclibs / ucrate

Scholar@UC: University of Cincinnati's self-submission institutional repository
https://scholar.uc.edu
Other
5 stars 3 forks source link

Files created by proxies don't give edit access to owners #488

Closed hortongn closed 5 years ago

hortongn commented 5 years ago

Descriptive summary

If I'm a proxy and create a work with some files attached on behalf of another user (the owner), that owner will have edit access to the work, but not to the files.

The owner should be able to edit any file sets created by their proxies.

This is probably a bug in our app where we broke it somewhere, but we should verify that Hyrax doesn't have the bug. You can test at https://nurax-dev.curationexperts.com

Steps to reproduce the behavior

  1. Create a work with file(s) as a proxy
  2. Log in as the owner
  3. Visit the show page for one of the files
  4. Notice that you don't have an edit button
crowesn commented 5 years ago

@hortongn On what env was this encountered? I can't recreate the bug on nurax or local/dev.

screen shot 2018-11-06 at 10 11 00 am
hortongn commented 5 years ago

Hmm. I was running the app locally. I will try it again and report back here. We're you running :inline or :sidekiq?

hortongn commented 5 years ago

@crowesn OK, I just did some more testing in my local environment and confirmed this:

Inline jobs: A user with a work created by a proxy DOES have edit access to attached files.

Sidekiq jobs: A user with a work created by a proxy DOES NOT have edit access to attached files.

So the problem exists for me when using sidekiq. See if you can replicate that behavior in your environment.

crowesn commented 5 years ago

Created issue for this on hyrax. https://github.com/samvera/hyrax/issues/3416

scherztc commented 5 years ago

We need to check with the community to see if they are intending to solve this with 3.0 release.

scherztc commented 5 years ago

This might help : https://github.com/uclibs/scholar_uc/pull/1328/files

scherztc commented 5 years ago

https://github.com/samvera/hyrax/commit/90f7a9f0593e7c44bfbbe4a4cf4f446f9636a5f7#diff-542d307457b483902c56ac6c42e21456