[BUG] Infinitely Growing div during multi-file downloads #925

Closed
opened 2026-02-04 23:35:32 +03:00 by OVERLORD · 11 comments
Owner

Originally created by @wittymap on GitHub (Jun 10, 2023).

The bug

When downloading a lot of photos from the web client, the status dialog overflows (I'm downloading 2000 files now):
image

In the inspector, the width of this div is ever-expanding (the % is rapidly increasing as I watch it).
firefox_lz6l148H5z

aYQ6f1MVhe

The OS that Immich Server is running on

Windows 10

Version of Immich Server

v1.60.0

Platform with the issue

  • Server
  • Web
  • Mobile
Originally created by @wittymap on GitHub (Jun 10, 2023). ### The bug When downloading a lot of photos from the web client, the status dialog overflows (I'm downloading 2000 files now): ![image](https://github.com/immich-app/immich/assets/119261743/a6af8495-785d-4e4b-a4e7-8c6fbd74d892) In the inspector, the width of this div is ever-expanding (the % is rapidly increasing as I watch it). ![firefox_lz6l148H5z](https://github.com/immich-app/immich/assets/119261743/2a49bc07-004d-45a2-a7f6-3a06b4923eac) ![aYQ6f1MVhe](https://github.com/immich-app/immich/assets/119261743/342c1ecc-0901-4465-b39a-481e89048f4d) ### The OS that Immich Server is running on Windows 10 ### Version of Immich Server v1.60.0 ### Platform with the issue - [ ] Server - [X] Web - [ ] Mobile
Author
Owner

@alextran1502 commented on GitHub (Jun 10, 2023):

Can you describe how are you downloading a lot of files to help us reproduce this issue?

@alextran1502 commented on GitHub (Jun 10, 2023): Can you describe how are you downloading a lot of files to help us reproduce this issue?
Author
Owner

@wittymap commented on GitHub (Jun 10, 2023):

Gif added above to show ever-expanding div.

From the timeline, I am selecting all files from a date (~2000 in this case), and then clicking the download button on the 3-dots menu in the upper right of a corner.

Does this help?

@wittymap commented on GitHub (Jun 10, 2023): Gif added above to show ever-expanding div. From the timeline, I am selecting all files from a date (~2000 in this case), and then clicking the download button on the 3-dots menu in the upper right of a corner. Does this help?
Author
Owner

@alextran1502 commented on GitHub (Jun 10, 2023):

Since we have multiple ways of selecting and downloading files. I need to know the exact steps you performed to reproduce the issue

@alextran1502 commented on GitHub (Jun 10, 2023): Since we have multiple ways of selecting and downloading files. I need to know the exact steps you performed to reproduce the issue
Author
Owner

@wittymap commented on GitHub (Jun 10, 2023):

I refreshed the timeline page (/photos) to start from scratch. Browser is Firefox.

Then I selected all of the files from a date by clicking the date (:
image

Then I clicked download from the 3-dots menu:
image

Then the dialog appeared and stayed like this at 0% for about a minute:
image

Then the progress bar started moving and the bug happens:
image

Eventually, the progress bar disappears and the files download successfully as a large zip.

Does this help?

@wittymap commented on GitHub (Jun 10, 2023): I refreshed the timeline page (`/photos`) to start from scratch. Browser is Firefox. Then I selected all of the files from a date by clicking the date (: ![image](https://github.com/immich-app/immich/assets/119261743/c3c806d2-5a5e-4627-ae30-563c503ce509) Then I clicked download from the 3-dots menu: ![image](https://github.com/immich-app/immich/assets/119261743/8e896c52-e6ca-4f99-b908-2dec1051794d) Then the dialog appeared and stayed like this at 0% for about a minute: ![image](https://github.com/immich-app/immich/assets/119261743/b3e915f3-96ec-4660-ba2d-147ff0511b26) Then the progress bar started moving and the bug happens: ![image](https://github.com/immich-app/immich/assets/119261743/c6078caf-64c5-4953-90eb-503bd2a7c67e) Eventually, the progress bar disappears and the files download successfully as a large zip. Does this help?
Author
Owner

@alextran1502 commented on GitHub (Jun 10, 2023):

Thank you for the report. Does it happen with 1 file selected for download, how many files did you choose for this to happen?

@alextran1502 commented on GitHub (Jun 10, 2023): Thank you for the report. Does it happen with 1 file selected for download, how many files did you choose for this to happen?
Author
Owner

@wittymap commented on GitHub (Jun 10, 2023):

The original report was with 2129 files selected. I've been able to reproduce it on as few as 2 files (but not 1).

It does not happen with all photos and videos, and seems to affect motion photos most often (it has affected every motion photo I have tried it on). With the same two files, the behavior is the same every time.

No errors show up in the server logs.

@wittymap commented on GitHub (Jun 10, 2023): The original report was with 2129 files selected. I've been able to reproduce it on as few as 2 files (but not 1). It does not happen with all photos and videos, and seems to affect motion photos most often (it has affected every motion photo I have tried it on). With the same two files, the behavior is the same every time. No errors show up in the server logs.
Author
Owner

@ckhordiasma commented on GitHub (Jun 16, 2023):

hello, i am having the same issue, see attached image.

immich_bug

after some experimentation it seems to me as well that the problem only (or most frequently) occurs with motion photos, even when just selecting one motion photo. I am running v1.61.0

maybe the file size (and therefore progress indicator) is not calculated correctly for motion photos?

@ckhordiasma commented on GitHub (Jun 16, 2023): hello, i am having the same issue, see attached image. ![immich_bug](https://github.com/immich-app/immich/assets/8106034/568d47e7-0c02-49a0-a070-4f210926ed47) after some experimentation it seems to me as well that the problem only (or most frequently) occurs with motion photos, even when just selecting one motion photo. I am running v1.61.0 maybe the file size (and therefore progress indicator) is not calculated correctly for motion photos?
Author
Owner

@uhthomas commented on GitHub (Jun 16, 2023):

This is probably because e.lengthComputable is not check here:

f04e47803c/web/src/lib/utils/asset-utils.ts (L52)

@uhthomas commented on GitHub (Jun 16, 2023): This is probably because [e.lengthComputable](https://developer.mozilla.org/en-US/docs/Web/API/ProgressEvent/lengthComputable) is not check here: https://github.com/immich-app/immich/blob/f04e47803c3eb5b0d7b0bf7fc5c0a12fc74e7931/web/src/lib/utils/asset-utils.ts#L52
Author
Owner

@uhthomas commented on GitHub (Jun 16, 2023):

Hmm, maybe not. It looks like lengthComputable is always false because Immich isn't setting a Content-Length header (why?). I'll take a closer look.

@uhthomas commented on GitHub (Jun 16, 2023): Hmm, maybe not. It looks like `lengthComputable` is always false because Immich isn't setting a `Content-Length` header (why?). I'll take a closer look.
Author
Owner

@ckhordiasma commented on GitHub (Jun 16, 2023):

here's a sample motion image (i guess it gets split into a heic and a mov) that causes the error for me.
immich.zip

@ckhordiasma commented on GitHub (Jun 16, 2023): here's a sample motion image (i guess it gets split into a heic and a mov) that causes the error for me. [immich.zip](https://github.com/immich-app/immich/files/11774725/immich.zip)
Author
Owner

@uhthomas commented on GitHub (Jun 17, 2023):

fwiw I can reproduce this with motion photos on v1.57.1, I can't on v1.61.0 though.

image

@uhthomas commented on GitHub (Jun 17, 2023): fwiw I can reproduce this with motion photos on v1.57.1, I can't on v1.61.0 though. ![image](https://github.com/immich-app/immich/assets/9749173/9194ed9d-fadd-422e-b8dd-581e03373c4f)
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: immich-app/immich#925