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

[oCIS] Cannot dismiss the notification in the server activity tab #11974

Open
2 tasks done
saw-jan opened this issue Nov 8, 2024 · 4 comments
Open
2 tasks done

[oCIS] Cannot dismiss the notification in the server activity tab #11974

saw-jan opened this issue Nov 8, 2024 · 4 comments
Labels

Comments

@saw-jan
Copy link
Member

saw-jan commented Nov 8, 2024

Pre-submission Checks

  • I checked for similar issues, but could not find any. I also checked the closed issues. I could not contribute additional information to any existing issue.
  • I will take the time to fill in all the required fields. I know that the bug report may be dismissed otherwise due to lack of information.

Describe the bug

Nothing happens when clicking the notification dismiss button.

The request to delete the notification is wrong for ocis:

Incorrect Request:x:

DELETE https://192.168.56.1:9200/ocs/v2.php/apps/notifications/api/v1/notifications/c92bb8b1-7759-48f5-ad30-7a8450c75958

Correct request ✔️

DELETE https://192.168.56.1:9200/ocs/v2.php/apps/notifications/api/v1/notifications
body: {"ids":["c92bb8b1-7759-48f5-ad30-7a8450c75958"]}

Expected behavior

Notification gets dismissed/removed

Steps to reproduce the issue

  1. Add admin user to the desktop-client
  2. as demo user, share a file to admin from the oCIS server
  3. as admin user, try to dismiss the notification from the Server Activity tab

Screenshots

Screenshot from 2024-11-08 14-14-10

Logs

24-11-08 14:22:24:447 [ info gui.notifications ]:	Notification Link:  "DELETE" "https://192.168.56.1:9200/ocs/v2.php/apps/notifications/api/v1/notifications/c92bb8b1-7759-48f5-ad30-7a8450c75958"
24-11-08 14:22:24:447 [ info gui.activity ]:	Server Notification Request  "DELETE" "https://192.168.56.1:9200/ocs/v2.php/apps/notifications/api/v1/notifications/c92bb8b1-7759-48f5-ad30-7a8450c75958" on account "[email protected]:9200"
24-11-08 14:22:24:448 [ info sync.networkjob ]:	Created OCC::NotificationConfirmJob(OCC::Account("[email protected]:9200"), "https://192.168.56.1:9200/ocs/v2.php/apps/notifications/api/v1/notifications/c92bb8b1-7759-48f5-ad30-7a8450c75958", "DELETE", Original-Request-ID: "31f6a5a7-f143-4572-933f-15d605ac7222", X-Request-ID: "31f6a5a7-f143-4572-933f-15d605ac7222") for OCC::ActivityWidget(0x161b620, name = "OCC__ActivityWidget")
24-11-08 14:22:24:448 [ info sync.httplogger ]:	REQUEST 31f6a5a7-f143-4572-933f-15d605ac7222 {"request":{"body":{"length":0},"header":{"accept":"*/*","accept-language":"en_US","authorization":"Bearer eyJhbGciOiJQUzI1NiIsImtpZCI6InByaXZhdGUta2V5IiwidHlwIjoiSldUIn0.eyJhdWQiOiJ4ZFhPdDEzSkt4eW0xQjFRY0VuY2YyWERrTEFleE1CRndpVDlqNkVmaGhIRkpoczJLTTlqYmpUbWY4SkJYRTY5IiwiZXhwIjoxNzMxMDU1MzQwLCJpYXQiOjE3MzEwNTUwNDAsImlzcyI6Imh0dHBzOi8vMTkyLjE2OC41Ni4xOjkyMDAiLCJqdGkiOiJhYkg3YlBkRWx3MjNWWGVFVkFnbjVBU1plYURnSHRHTCIsImxnLmkiOnsiZG4iOiJBZG1pbiIsImlkIjoib3duQ2xvdWRVVUlEPTVlY2Y2ZDlkLTQxODktNGJiZC1hNmQxLWIxZmE1ZWIzZTM5NyIsInVuIjoiYWRtaW4ifSwibGcucCI6ImlkZW50aWZpZXItbGRhcCIsImxnLnQiOiIxIiwic2NwIjoib3BlbmlkIG9mZmxpbmVfYWNjZXNzIGVtYWlsIHByb2ZpbGUiLCJzdWIiOiJhVmZqSE1BM2lBa1MyMHVLQC1Nc1l2TF9ka3ZhbXEzdXZQQUw1bS0xd3dPM2ROZFZVYUE4U09hU1hVaGczWXZDMENIa3FnLUF6LW5OWlZSMzlKREh0alEifQ.l1Mr9BgNFZNzzdpfEu5xIJLqsjkcVrRw34nCSCctxnuc7WGYHJQLHX_cRHCaeKU3L7EjTGZ20SQlWClvex3rU6vqLOpkNWtxz8_XalivGyQMy1XAyeGKzz9e119VjYCnVSeaHp-rnvjlM0FhB3SGAphzkNUllLRIslObDCHe9HnAprzev18qPLvVXZ8JsChOTP4IRcJWvwQsjyvveF-GeHZejOI-wEOVHeAbwumMUg42ga7tipXNI-KG6Q36kWc0clizbtjp9EI0rmGza8XwoKMAf-XYs-cbcKNaoy7dwDH-_PB1rAb-fEbtUSFsXQHXvOzZ2_DnrNwa726srdcWkVecdllSV-GojtYooaV9Wk1-vRr7rMi8koXvJJJsasjAEITJYj3EhYOVOFKSnVd7V0SbLKS_1Hyg_5sOC8zeImeDK2OSufMFCs4kw8uQKzh8gvyn31HNkvX8FdmhdWyYO2JNA2vuXulYKtrWipQ8H47nV3nUwVTkvc7RJUyTsIy_imbqk94LdP1ZBYSeHAYAPx5Lm8GQQimDi8hx6dHJ2q3-_uD6NJG-zHmPhyPxCJpmkT-qnppTl909QK7HK92n_RqYEZ1hKhPBQKFovbwD0du6Sgb_Te3Io1wzvZ_t1BZEzwma-rY5kN7GrUaM-EU4jKp-VCUm8D2X7-KNclFHID0","original-request-id":"31f6a5a7-f143-4572-933f-15d605ac7222","user-agent":"Mozilla/5.0 (Linux) mirall/6.0.0.14906-daily20241029 (ownCloud, ubuntu-6.2.0-39-generic ClientArchitecture: x86_64 OsArchitecture: x86_64)","x-request-id":"31f6a5a7-f143-4572-933f-15d605ac7222"},"info":{"cached":false,"id":"31f6a5a7-f143-4572-933f-15d605ac7222","method":"DELETE","url":"https://192.168.56.1:9200/ocs/v2.php/apps/notifications/api/v1/notifications/c92bb8b1-7759-48f5-ad30-7a8450c75958"}}}
24-11-08 14:22:24:451 [ info sync.httplogger ]:	RESPONSE 31f6a5a7-f143-4572-933f-15d605ac7222 {"response":{"body":{"data":"19 bytes of  data","length":19},"header":{"content-length":"19","content-security-policy":"child-src 'self'; connect-src 'self' blob: https://raw.githubusercontent.com/owncloud/awesome-ocis/; default-src 'none'; font-src 'self'; frame-ancestors 'self'; frame-src 'self' blob: https://embed.diagrams.net/; img-src 'self' data: blob: https://raw.githubusercontent.com/owncloud/awesome-ocis/; manifest-src 'self'; media-src 'self'; object-src 'self' blob:; script-src 'self' 'unsafe-inline'; style-src 'self' 'unsafe-inline'","content-type":"text/plain; charset=utf-8","date":"Fri, 08 Nov 2024 08:37:24 GMT","referrer-policy":"strict-origin-when-cross-origin","strict-transport-security":"max-age=315360000; preload","vary":"Origin","x-content-type-options":"nosniff, nosniff","x-frame-options":"SAMEORIGIN","x-permitted-cross-domain-policies":"none","x-request-id":"31f6a5a7-f143-4572-933f-15d605ac7222","x-robots-tag":"none","x-userlog-version":"6.6.1","x-xss-protection":"1; mode=block"},"info":{"id":"31f6a5a7-f143-4572-933f-15d605ac7222","method":"DELETE","reply":{"cached":false,"duration":2,"durationString":"duration(0h, 0min, 0s, 2ms)","error":"Error transferring https://192.168.56.1:9200/ocs/v2.php/apps/notifications/api/v1/notifications/c92bb8b1-7759-48f5-ad30-7a8450c75958 - server replied: Not Found","status":404,"version":"HTTP 2"},"url":"https://192.168.56.1:9200/ocs/v2.php/apps/notifications/api/v1/notifications/c92bb8b1-7759-48f5-ad30-7a8450c75958"}}}
24-11-08 14:22:24:451 [ warning sync.networkjob.jsonapi ]:	Network error:  OCC::NotificationConfirmJob(OCC::Account("[email protected]:9200"), "https://192.168.56.1:9200/ocs/v2.php/apps/notifications/api/v1/notifications/c92bb8b1-7759-48f5-ad30-7a8450c75958", "DELETE", Original-Request-ID: "31f6a5a7-f143-4572-933f-15d605ac7222", X-Request-ID: "31f6a5a7-f143-4572-933f-15d605ac7222", NetworkError: "Error transferring https://192.168.56.1:9200/ocs/v2.php/apps/notifications/api/v1/notifications/c92bb8b1-7759-48f5-ad30-7a8450c75958 - server replied: Not Found") "Server replied \"404 Not Found\" to \"DELETE https://192.168.56.1:9200/ocs/v2.php/apps/notifications/api/v1/notifications/c92bb8b1-7759-48f5-ad30-7a8450c75958\""
24-11-08 14:22:24:451 [ warning gui.notifications ]:	Notification Request to Server failed, leave button visible.
24-11-08 14:22:24:451 [ warning gui.activity ]:	Server notify job failed with code  0
24-11-08 14:22:24:451 [ debug sync.networkjob ]	[ OCC::AbstractNetworkJob::slotFinished ]:	Network job finished OCC::NotificationConfirmJob(OCC::Account("[email protected]:9200"), "https://192.168.56.1:9200/ocs/v2.php/apps/notifications/api/v1/notifications/c92bb8b1-7759-48f5-ad30-7a8450c75958", "DELETE", Original-Request-ID: "31f6a5a7-f143-4572-933f-15d605ac7222", X-Request-ID: "31f6a5a7-f143-4572-933f-15d605ac7222", NetworkError: "Error transferring https://192.168.56.1:9200/ocs/v2.php/apps/notifications/api/v1/notifications/c92bb8b1-7759-48f5-ad30-7a8450c75958 - server replied: Not Found")
DELETE https://192.168.56.1:9200/ocs/v2.php/apps/notifications/api/v1/notifications/c92bb8b1-7759-48f5-ad30-7a8450c75958

> 404 Not Found

Client version number

Tested on client 6.0.0 and 5.3.1

Server information

Tested on:
Infinite Scale 4.0.7 Community
Infinite Scale 5.0.7 Community
Infinite Scale 7.0.0-rc.1 Community

@DeepDiver1975
Copy link
Member

So ocis and oc10 Apis are not compatible? Or am I missing anything

@kobergj

@saw-jan
Copy link
Member Author

saw-jan commented Nov 8, 2024

In this case, yes!

@kobergj
Copy link

kobergj commented Nov 8, 2024

No. They are not compatible. This issue is know since long: https://github.com/owncloud/enterprise/issues/6307 owncloud/ocis#5675 (comment)

@saw-jan
Copy link
Member Author

saw-jan commented Nov 8, 2024

In this case, yes!

I meant, the way notification is deleted is different in ocis and oc10.
In oC10, notification id is used in the url path not in the body like ocis

DELETE http://localhost:8080/ocs/v2.php/apps/notifications/api/v1/notifications/1

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants