Skip to content

Conversation

@alexknop
Copy link
Collaborator

Problem:

Although Videos were loading immediately when offline, Images were not

Solution:
Found that checking for whether file is offline was passing, but the ! in the code was making it false, forcing a sync which would timeout (taking extra time) and preventing immediate access to images

Fixes #14470

@github-actions
Copy link

Hello there,
Thank you so much for taking the time and effort to create a pull request to our Nextcloud project.

We hope that the review process is going smooth and is helpful for you. We want to ensure your pull request is reviewed to your satisfaction. If you have a moment, our community management team would very much appreciate your feedback on your experience with this PR review process.

Your feedback is valuable to us as we continuously strive to improve our community developer experience. Please take a moment to complete our short survey by clicking on the following link: https://cloud.nextcloud.com/apps/forms/s/i9Ago4EQRZ7TWxjfmeEpPkf6

Thank you for contributing to Nextcloud and we hope to hear from you soon!

(If you believe you should not receive this message, you can add yourself to the blocklist.)

@alexknop alexknop force-pushed the ImageTimeout branch 3 times, most recently from 29d419f to 78cd829 Compare April 28, 2025 13:39
@tobiasKaminsky
Copy link
Member

Thanks for the fix.
Please see #14470 (comment)

I cannot reproduce it on master, thus I cannot test the fix.

@alexknop
Copy link
Collaborator Author

alexknop commented May 7, 2025

Thanks for the fix. Please see #14470 (comment)

I cannot reproduce it on master, thus I cannot test the fix.

Check #14470 (comment) where displaying the video is working fine but then I try to select an image after and it won't load.
However looking at my proposed changes, don't we want to properly check if the image is downloaded before passing to the startImagePreview() function?

@tobiasKaminsky
Copy link
Member

👍 You are right.
I mixed things up.

I will rebase, so that CI runs again.

Signed-off-by: knopalex <knopalex@msu.edu>
@github-actions
Copy link

Codacy

Lint

TypemasterPR
Warnings5151
Errors1111

SpotBugs

CategoryBaseNew
Bad practice6565
Correctness5859
Dodgy code292279
Experimental11
Internationalization77
Malicious code vulnerability11
Multithreaded correctness77
Performance5148
Security1818
Total500485

@github-actions
Copy link

APK file: https://www.kaminsky.me/nc-dev/android-artifacts/14733.apk

qrcode

To test this change/fix you can simply download above APK file and install and test it in parallel to your existing Nextcloud app.

@tobiasKaminsky tobiasKaminsky merged commit 306d5f3 into master May 28, 2025
19 of 20 checks passed
@tobiasKaminsky tobiasKaminsky deleted the ImageTimeout branch May 28, 2025 07:54
@tobiasKaminsky tobiasKaminsky added this to the Nextcloud App 3.32.0 milestone May 28, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Cannot Open Offline Photos After Video

4 participants