tubearchivist icon indicating copy to clipboard operation
tubearchivist copied to clipboard

[Bug]: FileNotFoundError when fetching metadata for downloaded video.

Open AdamGaffney96 opened this issue 8 months ago • 9 comments

I've read the documentation

Operating System

Synology

Your Bug Report

Describe the bug

When attempting to download any YouTube video manually, I get the log output below and the video just remains in the queue undownloaded. I have tried restarting the containers, plus re-pulling the images also using my attached docker-compose to no success. I specify manual because my scheduled downloads still work, I wake up every day to a couple new videos successfully downloaded by the scheduled process overnight from my subscriptions. However if I try to manually add videos using the "Add to download queue" button this happens every time.

Steps To Reproduce

  • Copy a YouTube link
  • Click "Add to download queue" and paste link
  • Click either "Add to queue" then hit "Start download", or just use "Download now", both have the same issue

Expected behavior

Video should download normally

Relevant log output

20/06/2024
11:00:40
[2024-06-20 11:00:40,869: INFO/MainProcess] Task extract_download[111a0cae-0db8-4453-85fe-f532a8a0a4a0] received
20/06/2024
11:00:41
[2024-06-20 11:00:40,870: WARNING/ForkPoolWorker-5] extract_download create callback
20/06/2024
11:00:41
[2024-06-20 11:00:41,782: WARNING/ForkPoolWorker-5] HwF229U2ba8: [1/1]: add to queue
20/06/2024
11:00:46
[2024-06-20 11:00:46,882: INFO/MainProcess] Task download_pending[fe5ad2d1-ccda-4eba-85df-daf48af3bf0e] received
20/06/2024
11:00:46
[2024-06-20 11:00:46,884: WARNING/ForkPoolWorker-2] download_pending create callback
20/06/2024
11:00:46
[2024-06-20 11:00:46,928: WARNING/ForkPoolWorker-5] 111a0cae-0db8-4453-85fe-f532a8a0a4a0 success callback
20/06/2024
11:00:46
[2024-06-20 11:00:46,935: INFO/ForkPoolWorker-5] Task extract_download[111a0cae-0db8-4453-85fe-f532a8a0a4a0] succeeded in 6.057595910038799s: 'added 1 Videos to Queue'
20/06/2024
11:00:46
[2024-06-20 11:00:46,935: WARNING/ForkPoolWorker-5] 111a0cae-0db8-4453-85fe-f532a8a0a4a0 return callback
20/06/2024
11:00:46
[2024-06-20 11:00:46,940: WARNING/ForkPoolWorker-2] 4u78DVLEnvw: Downloading video
20/06/2024
11:00:52
[2024-06-20 11:00:52,024: WARNING/ForkPoolWorker-2] 4u78DVLEnvw: get metadata from youtube
20/06/2024
11:00:56
[2024-06-20 11:00:56,453: WARNING/ForkPoolWorker-2] UCPDXXXJj9nax0fr0Wfc048g: get metadata from es
20/06/2024
11:00:56
[2024-06-20 11:00:56,463: WARNING/ForkPoolWorker-2] fe5ad2d1-ccda-4eba-85df-daf48af3bf0e Failed callback
20/06/2024
11:00:56
[2024-06-20 11:00:56,466: ERROR/ForkPoolWorker-2] Task download_pending[fe5ad2d1-ccda-4eba-85df-daf48af3bf0e] raised unexpected: FileNotFoundError()
20/06/2024
11:00:56
Traceback (most recent call last):
20/06/2024
11:00:56
  File "/root/.local/lib/python3.11/site-packages/celery/app/trace.py", line 453, in trace_task
20/06/2024
11:00:56
    R = retval = fun(*args, **kwargs)
20/06/2024
11:00:56
                 ^^^^^^^^^^^^^^^^^^^^
20/06/2024
11:00:56
  File "/root/.local/lib/python3.11/site-packages/celery/app/trace.py", line 736, in __protected_call__
20/06/2024
11:00:56
    return self.run(*args, **kwargs)
20/06/2024
11:00:56
           ^^^^^^^^^^^^^^^^^^^^^^^^^
20/06/2024
11:00:56
  File "/app/home/tasks.py", line 128, in download_pending
20/06/2024
11:00:56
                        ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
20/06/2024
11:00:56
  File "/app/home/src/download/yt_dlp_handler.py", line 73, in run_queue
20/06/2024
11:00:56
  File "/app/home/src/index/video.py", line 398, in index_new_video
20/06/2024
11:00:56
    video.build_json()
20/06/2024
11:00:56
    self.add_player(media_path)
20/06/2024
11:00:56
  File "/app/home/src/index/video.py", line 248, in add_player

Anything else?

Here is the docker compose I used to create the containers I'm trying to think of anything else I have changed since this began but I can't think of anything. I updated directly from v0.4.2 to v0.4.8 a couple weeks ago, however I only noticed this start happening in the last couple of days. I only found one issue previously referencing a FileNotFoundError but it didn't seem to be the same issue and the fixes didn't work if I recall right.

AdamGaffney96 avatar Jun 20 '24 10:06 AdamGaffney96