instructure / canvas-lms

The open LMS by Instructure, Inc.
https://github.com/instructure/canvas-lms/wiki
GNU Affero General Public License v3.0
5.57k stars 2.48k forks source link

Can't download group of files. #2226

Open Yetoo1 opened 1 year ago

Yetoo1 commented 1 year ago

Summary:

As of 68a39b7f70805f55258248b4a80e28503a9088de in master (this has been occurring longer than a couple of days, not sure when it started), when I try downloading a group of uploaded files via account -> Files the Downloading progress indicator stays at 0.

Steps to reproduce:

  1. git clone https://github.com/instructure/canvas-lms.git
  2. Apply the patches here: https://github.com/instructure/canvas-lms/issues/2199#issuecomment-1565682018 so that ./script/docker_dev_setup.sh or ./script/docker_dev_update.sh doesn't fail.
  3. cd into the cloned repo and follow https://github.com/instructure/canvas-lms/tree/master/doc/docker to add user to group docker-instructure to avoid permission problems. I skipped the setfacl steps because my user is already part of docker-instructure from past attempts and no errors happen when skipping setfacl steps on fresh repo clones.
  4. Run ./script/docker_dev_setup.sh and skip setting up Dory.
  5. enter \<ip of web container> canvas.docker canvas into /etc/hosts
  6. open Firefox on server
  7. Login to admin account set up when setting up the database.
  8. Click Account.
  9. Click on Files.
  10. Go to the My Files directory.
  11. Upload more than one file.
  12. Control click to select more than one of the uploaded files.
  13. Press the download button.

Expected behavior:

Preparing to download finishes and downloads to default location (depending on browser config).

Actual behavior:

The Preparing download progress notification is stuck at 0% complete.

Additional notes:

Here is a snippet of the logs after pressing the download button: 172.20.0.1 - - [28/Jun/2023:21:55:04 +0000] "POST /api/v1/users/1/content_exports HTTP/1.1" 200 172 "http://canvas.docker/files" "Mozilla/5.0 (X11; Ubuntu; Linux x86_64; rv:109.0) Gecko/20100101 Firefox/114.0" 172.20.0.1 - - [28/Jun/2023:21:55:04 +0000] "GET /api/v1/progress/12 HTTP/1.1" 200 287 "http://canvas.docker/files" "Mozilla/5.0 (X11; Ubuntu; Linux x86_64; rv:109.0) Gecko/20100101 Firefox/114.0" 172.20.0.1 - - [28/Jun/2023:21:55:05 +0000] "GET /api/v1/progress/12 HTTP/1.1" 304 0 "http://canvas.docker/files" "Mozilla/5.0 (X11; Ubuntu; Linux x86_64; rv:109.0) Gecko/20100101 Firefox/114.0" 172.20.0.1 - - [28/Jun/2023:21:55:06 +0000] "GET /api/v1/progress/12 HTTP/1.1" 304 0 "http://canvas.docker/files" "Mozilla/5.0 (X11; Ubuntu; Linux x86_64; rv:109.0) Gecko/20100101 Firefox/114.0" 172.20.0.1 - - [28/Jun/2023:21:55:07 +0000] "GET /api/v1/progress/12 HTTP/1.1" 304 0 "http://canvas.docker/files" "Mozilla/5.0 (X11; Ubuntu; Linux x86_64; rv:109.0) Gecko/20100101 Firefox/114.0" 172.20.0.1 - - [28/Jun/2023:21:55:08 +0000] "GET /api/v1/progress/12 HTTP/1.1" 304 0 "http://canvas.docker/files" "Mozilla/5.0 (X11; Ubuntu; Linux x86_64; rv:109.0) Gecko/20100101 Firefox/114.0" 172.20.0.1 - - [28/Jun/2023:21:55:09 +0000] "GET /api/v1/users/self/tabs HTTP/1.1" 304 0 "http://canvas.docker/files" "Mozilla/5.0 (X11; Ubuntu; Linux x86_64; rv:109.0) Gecko/20100101 Firefox/114.0" 172.20.0.1 - - [28/Jun/2023:21:55:11 +0000] "GET /api/v1/progress/12 HTTP/1.1" 304 0 "http://canvas.docker/files" "Mozilla/5.0 (X11; Ubuntu; Linux x86_64; rv:109.0) Gecko/20100101 Firefox/114.0" 172.20.0.1 - - [28/Jun/2023:21:55:11 +0000] "GET /api/v1/files/4 HTTP/1.1" 304 0 "http://canvas.docker/files" "Mozilla/5.0 (X11; Ubuntu; Linux x86_64; rv:109.0) Gecko/20100101 Firefox/114.0" 172.20.0.1 - - [28/Jun/2023:21:55:11 +0000] "GET /api/v1/files/3 HTTP/1.1" 304 0 "http://canvas.docker/files" "Mozilla/5.0 (X11; Ubuntu; Linux x86_64; rv:109.0) Gecko/20100101 Firefox/114.0" 172.20.0.1 - - [28/Jun/2023:21:55:12 +0000] "GET /api/v1/progress/12 HTTP/1.1" 304 0 "http://canvas.docker/files" "Mozilla/5.0 (X11; Ubuntu; Linux x86_64; rv:109.0) Gecko/20100101 Firefox/114.0"

Judging by the 304 codes, the server is telling the browser to read from cache. I have cleared browser cache and reproduced this behavior in private browsing mode in Firefox. Is anyone else experiencing this?