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

[Bug]: Error creating the share : item is already shared with user #45436

Open
5 of 8 tasks
dorianne-arawa opened this issue May 22, 2024 · 0 comments
Open
5 of 8 tasks
Labels
0. Needs triage Pending check for reproducibility or if it fits our roadmap 27-feedback bug feature: sharing

Comments

@dorianne-arawa
Copy link

⚠️ This issue respects the following points: ⚠️

Bug description

On instances with Nexcloud versions 27.1.7 and 27.1.9, public email share links display an error when created, whereas they are in fact created (and displayed on page reload only).

Full error message : Error creating the share failed, because this item is already shared with user

On the first click to confirm the share, the request is sent, but the front end displays nothing. The user clicks a second time and receives an error (but the share was created on the first click).

Steps to reproduce

  1. go to a folder and open its Sharing parameters
  2. enter an external e-mail address (not existing on the instance) in the first Search for share recipients field
  3. click on the desired e-mail address (make sure you have the e-mail icon at the end of the line)
  4. click once on Save share : nothing happens in the user interface
  5. click on Save share a second time: the error message appears (Error creating the share <file name> failed, because this item is already shared with user <email address>)
  6. reload the page: the e-mail link has now been created

Expected behavior

  1. go to a folder and open its Sharing parameters
  2. enter an external e-mail address (not existing on the instance) in the first Search for share recipients field
  3. click on the desired e-mail address (make sure you have the e-mail icon at the end of the line)
  4. click once on Save share : the share is created, without error message

Installation method

Community Manual installation with Archive

Nextcloud Server version

27

Operating system

RHEL/CentOS

PHP engine version

PHP 8.1

Web server

Nginx

Database engine version

MariaDB

Is this bug present after an update or on a fresh install?

None

Are you using the Nextcloud Server Encryption module?

Encryption is Disabled

What user-backends are you using?

  • Default user-backend (database)
  • LDAP/ Active Directory
  • SSO - SAML
  • Other

Configuration report

No response

List of activated Apps

No response

Nextcloud Signing status

No response

Nextcloud Logs

./nextcloud.log:{"reqId":"2tiqC3NkXfRYeoJPlt8X","level":0,"time":"2024-05-22T12:11:01+02:00","remoteAddr":"37.171.179.29","user":"user","app":"Federated File Sharing","method":"POST","url":"/ocs/v2.php/apps/files_sharing/api/v1/shares","message":"Sharing Talk failed, because this item is already shared with user test@example\.fr","userAgent":"Mozilla/5.0 (X11; Ubuntu; Linux x86_64; rv:126.0) Gecko/20100101 Firefox/126.0","version":"27.1.9.1","data":{"app":"Federated File Sharing"}}
./nextcloud.log:{"reqId":"2tiqC3NkXfRYeoJPlt8X","level":3,"time":"2024-05-22T12:11:01+02:00","remoteAddr":"37.171.179.29","user":"user","app":"no app in context","method":"POST","url":"/ocs/v2.php/apps/files_sharing/api/v1/shares","message":"Exception thrown: Exception","userAgent":"Mozilla/5.0 (X11; Ubuntu; Linux x86_64; rv:126.0) Gecko/20100101 Firefox/126.0","version":"27.1.9.1","exception":{"Exception":"Exception","Message":"Le partage de Talk a \u00e9chou\u00e9, parce que cet \u00e9l\u00e9ment est d\u00e9j\u00e0 partag\u00e9 avec l'utilisateur test@example\.fr","Code":0,"Trace":[{"file":"/var/www/html/nextcloud/nextcloud\.domain\.fr/lib/private/Share20/Manager.php","line":828,"function":"create","class":"OCA\\ShareByMail\\ShareByMailProvider","type":"->","args":["*** sensitive parameters replaced ***"]},{"file":"/var/www/html/nextcloud/nextcloud\.domain\.fr/apps/files_sharing/lib/Controller/ShareAPIController.php","line":823,"function":"createShare","class":"OC\\Share20\\Manager","type":"->","args":["*** sensitive parameters replaced ***"]},{"file":"/var/www/html/nextcloud/nextcloud\.domain\.fr/lib/private/AppFramework/Http/Dispatcher.php","line":230,"function":"createShare","class":"OCA\\Files_Sharing\\Controller\\ShareAPIController","type":"->","args":["*** sensitive parameters replaced ***"]},{"file":"/var/www/html/nextcloud/nextcloud\.domain\.fr/lib/private/AppFramework/Http/Dispatcher.php","line":137,"function":"executeController","class":"OC\\AppFramework\\Http\\Dispatcher","type":"->","args":[["OCA\\Files_Sharing\\Controller\\ShareAPIController"],"createShare"]},{"file":"/var/www/html/nextcloud/nextcloud\.domain\.fr/lib/private/AppFramework/App.php","line":183,"function":"dispatch","class":"OC\\AppFramework\\Http\\Dispatcher","type":"->","args":[["OCA\\Files_Sharing\\Controller\\ShareAPIController"],"createShare"]},{"file":"/var/www/html/nextcloud/nextcloud\.domain\.fr/lib/private/Route/Router.php","line":315,"function":"main","class":"OC\\AppFramework\\App","type":"::","args":["OCA\\Files_Sharing\\Controller\\ShareAPIController","createShare",["OC\\AppFramework\\DependencyInjection\\DIContainer"],["ocs.files_sharing.ShareAPI.createShare"]]},{"file":"/var/www/html/nextcloud/nextcloud\.domain\.fr/ocs/v1.php","line":65,"function":"match","class":"OC\\Route\\Router","type":"->","args":["/ocsapp/apps/files_sharing/api/v1/shares"]},{"file":"/var/www/html/nextcloud/nextcloud\.domain\.fr/ocs/v2.php","line":23,"args":["/var/www/html/nextcloud/nextcloud\.domain\.fr/ocs/v1.php"],"function":"require_once"}],"File":"/var/www/html/nextcloud/nextcloud\.domain\.fr/apps/sharebymail/lib/ShareByMailProvider.php","Line":181,"CustomMessage":"Exception thrown: Exception"}}

Additional info

Uploading 2190 bug partages externes mails.png…

@dorianne-arawa dorianne-arawa added 0. Needs triage Pending check for reproducibility or if it fits our roadmap bug labels May 22, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
0. Needs triage Pending check for reproducibility or if it fits our roadmap 27-feedback bug feature: sharing
Projects
None yet
Development

No branches or pull requests

3 participants