Closed amrita-shrestha closed 1 month ago
For reference, log entry below:
{"level":"error","service":"collaboration","request-id":"","proto":"HTTP/1.1","method":"GET","path":"/wopi/files/3087b86e78853869ae2ec56a7cc646cbf8b8d9e058ed123dcf19ced87e57cd86","WopiSessionId":"","WopiOverride":"","WopiProof":"","WopiProofOld":"","WopiStamp":"","FileReference":"resource_id:{storage_id:\"7edebe16-6335-47a0-bf76-3885202dffcf\" opaque_id:\"22f17a98-4255-4c1b-856f-f64b5a36917e\" space_id:\"542053c5-dafc-45c8-92e2-6bb01a8bec29\"} path:\".\"","ViewMode":"VIEW_MODE_READ_WRITE","Requester":"idp:\"https://ocis.jp.solidgear.prv\" opaque_id:\"542053c5-dafc-45c8-92e2-6bb01a8bec29\" type:USER_TYPE_PRIMARY","StatusCode":"CODE_NOT_FOUND","StatusMsg":"stat: error: not found: ","time":"2024-09-18T16:04:50Z","line":"/home/juan/src/ocis/ocis/services/collaboration/pkg/connector/fileconnector.go:1060","message":"CheckFileInfo: stat failed with unexpected status"}
We can detect that case and return an appropriate 404 error
fix PR has been merged and the test has been covered so closing this issue
Describe the bug
try to get file info using wopi, which returns 500 if a file has been deleted
Steps to reproduce
/app/open?app_name=$app&file_id=$fileId
returnsExpected behavior
401 unauthorized or 404 code should be return
Actual behavior
500 status code returned
Setup
Please describe how you started the server and provide a list of relevant environment variables or configuration files.
```console ownCloud Infinite Scale Edition Community Version 6.3.0+283948487 Web client version 10.2.0 ```
Additional context
Add any other context about the problem here.