You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
[BUG] Deeplinks without connection, not working #4251
Get the link of the file and create a deep link (adding owncloud:// as prefix)
Remove device connection
Click on the link to open
Actual behaviour
Sync failed
Expected behaviour
File is downloaded (therefore discovered), so it should be opened in the app, regardless the lack of connection.
If file is discovered and not downloaded, opening the link should show the Details view, no matter if the file is previewable or not (same as clicking directly the file)
If the file is downloaded, lack of connection does not have to avoid opening it.
If a folder is discovered, it should show the content
Still reproducible on current master. Located cause:
ManageDeepLinkUseCase.run() → FileRepository.getFileFromRemoteId() is remote-only. OCFileRepository.getFileFromRemoteId() (owncloudData/.../OCFileRepository.kt:169) immediately does remoteFileDataSource.getMetaFile(fileId, accountName) to resolve fileId → path, then loops refreshFolder(...) over every path segment. All are network calls; offline they fail → Sync failed, even for an already-discovered/downloaded file.
There is no local-DB fast path: the use case never consults the local store before going remote, so the "file already discovered/downloaded ⇒ open without connection" expectation can't be met as written.
Fix direction: resolve the deep link against the local DB first (look up by remoteId/fileId locally), and only fall back to the remote getMetaFile/refreshFolder resolution when the item isn't discovered locally — surface the offline error only in that last case (matches the issue's bullet list). The remote-resolution path can stay for the not-discovered case.
(Earlier attempt PR #3598 "Open deep links in app, items already discovered (1st round)" was closed unmerged; the shipped deep-link handling did not include offline/local-first resolution.)
Activity
DeepDiver1975 commentedon Jun 30, 2026
Still reproducible on current
master. Located cause:ManageDeepLinkUseCase.run()→FileRepository.getFileFromRemoteId()is remote-only.OCFileRepository.getFileFromRemoteId()(owncloudData/.../OCFileRepository.kt:169) immediately doesremoteFileDataSource.getMetaFile(fileId, accountName)to resolve fileId → path, then loopsrefreshFolder(...)over every path segment. All are network calls; offline they fail →Sync failed, even for an already-discovered/downloaded file.There is no local-DB fast path: the use case never consults the local store before going remote, so the "file already discovered/downloaded ⇒ open without connection" expectation can't be met as written.
Fix direction: resolve the deep link against the local DB first (look up by remoteId/fileId locally), and only fall back to the remote
getMetaFile/refreshFolderresolution when the item isn't discovered locally — surface the offline error only in that last case (matches the issue's bullet list). The remote-resolution path can stay for the not-discovered case.(Earlier attempt PR #3598 "Open deep links in app, items already discovered (1st round)" was closed unmerged; the shipped deep-link handling did not include offline/local-first resolution.)
🤖 Generated with Claude Code