sciencemesh / cs3api4lab

CS3APIs Jupyterlab connector
Apache License 2.0
4 stars 11 forks source link

Enable updating received shares #59

Open mateusz-garlacz opened 3 years ago

mateusz-garlacz commented 3 years ago

Hi @diocas It seems that during development of the plugin we omitted important part of sharing flow. So the proper flow is:

Currently the user is not able to update the share on our UI and as the matter of fact the files from shares are not available. It turns out that the files visible under 'Shared with me' tab can be read because of a bug (I suppose) in reva allowing every user to read every directory of other users wthin the same provider without any restrictions. E.g. that is why 'einstein' is able to read files in '/reva/marie' directory. However it is impossible to bypass it in case of OCM shares - the user needs to accept share in order to read the file from /home/MyShares, because remote directories are unreachable. So I presume the options are:

Please consider it in spare moment. Regards!

diocas commented 3 years ago

Hi @mateusz-garlacz ,

It's true we're missing the acceptance of a share. Maybe I would put another accordion entry, above "shared with me", called "pending shares". I would not accept automatically. image

As for how to access them, the plans are changing and the shares will no longer appear under /home/Myshares. This for us is not a problem since we always said we didn't want this folder and were going to access them from the shares tab. The access to other users needs to work... I.e, in CERNBox we are planning to expose via REVA the full EOS namespace, so when you open a share you're redirected to /eos/user/o/otheruser/sharedfolder (this is already available in our test instance).

I would check how the cmd client does this, as I think the sharing access was implemented there already (@ishank011 can you confim?)

ishank011 commented 3 years ago

The reva GRPC services always return the full path. The change was made in ocs since it was truncating the paths https://github.com/cs3org/reva/pull/1605. If you want to use the HTTP endpoints, you can cherry pick this PR, otherwise you can just stat the resource infos returned by ListShares.