kalibrado / trailer-finder

Trailer Finder is a tool that automatically searches and downloads movie trailers for your media collection. It integrates with media management tools like Radarr and Sonarr to keep your trailers up-to-date.
MIT License
15 stars 0 forks source link

It can't find movies #22

Closed TaylanTatli closed 1 month ago

TaylanTatli commented 1 month ago

Describe the bug I installed with docker. When it starts just shows:

 [ MAIN ] Starting trailer finder. 
     -------------------------------- 
 [ RADARR ] Movie trailer finder started. 
 [ RADARR ] Movie trailer finder ended. 

There are hundreds of movies.

To Reproduce Steps to reproduce the behavior:

  1. Deploy the container
  2. See the logs

Expected behavior It should find the movies and start dowloading trailers

Screenshots If applicable, add screenshots to help explain your problem.

Desktop (please complete the following information):

Additional context Here is the config:

# Sonarr configuration
# sonarr_host: "http://localhost:8989"
# sonarr_api: "your_sonarr_api_key"

# Radarr configuration
radarr_host: "removedtoshare"
radarr_api: "removedtoshare"

# TMDB API key (The Movie Database)
tmdb_api: "removedtoshare"

# Output directory for trailers
dir_backdrops: "trailers"

# Base URL for YouTube links
yt_link_base: "https://www.youtube.com/watch?v="

# YouTube authentication information (optional)
# auth_yt_user: "your_youtube_username"
# auth_yt_pass: "your_youtube_password"

# Settings for downloading with Youtube-DL
no_warnings: False
skip_intros: True
max_length: 300
thread_count: 4
buffer_size_ffmpeg: "1M"
filetype: "mkv"

# Sleep time between executions in hours
sleep_time: 6

# YouTube search keywords for trailers
yt_search_keywords: "resmi fragman"

# Limit download to one trailer per item
only_one_trailer: True

# Minimum free disk space required in GB
min_free_space_gb: 5

# Default language for translation
default_locale: en

# Default language for trailers
default_language_trailer: tr-TR

# Quiet mode, suppress some logs for yt_dlp and ffmpeg process
quiet_mode: False

And here is the docker compose:

version: "3"
services:
  trailer-finder:
    image: ldfe/trailer-finder:v1.3.2
    container_name: trailer-finder
    restart: unless-stopped
    network_mode: bridge
    security_opt:
      - no-new-privileges:true
    volumes:
      - type: bind
        source: /SSD/AppData/trailer-finder/config/config.yaml
        target: /app/config/config.yaml
      - type: bind
        source: /DATA/Media/Movies
        target: /movies
kalibrado commented 1 month ago

Hi there 👋

Thank you for using Trailer Finder!

I just released a corrective update, version 1.4.2.

Here is an example of a Docker Compose file:

version: "3"
services:
  trailer-finder:
    image: ldfe/trailer-finder:v1.4.2
    restart: always
    container_name: trailer-finder
    volumes:
      - ${ROOT}/trailer-finder/config.yaml:/app/config/config.yaml
      - /mnt:/mnt

For the YAML configuration file, there are also a few small changes 😊:

sonarr_host: "http://localhost:8989/"
sonarr_api: ""
radarr_host: "http://localhost:7878"
radarr_api: ""
tmdb_api: ""
yt_link_base: "https://www.youtube.com/watch?v="
auth_yt_user: ""
auth_yt_pass: ""
no_warnings: True
skip_intros: True
max_length: 200
thread_count: 4
buffer_size_ffmpeg: "1M"
filetype: "mkv"
sleep_time: 6
yt_search_keywords: "official trailer"
only_one_trailer: True
min_free_space_gb: 5
default_locale: en
default_language_trailer: en-EN
quiet_mode: False

TMDB_type_of_trailer: "Trailer" # Type of media to list, separated by "|" e.g., "Trailer|Featurette|Clip"
TMDB_official: True # Only official videos
TMDB_size: 1080 # Default size
TMDB_source: "YouTube" # Only valid YouTube sources (others coming soon)

dir_backdrops: "backdrops" # Default value for trailers, e.g., /path/of/movie/Movie Name/backdrops/
custom_path: "" # Set this if you want to save trailers in a specific path
custom_name_tv_show: "TV Show Trailer" # Valid only if custom_path is set
custom_name_movie: "Movie Trailers" # Valid only if custom_path is set

YT_DLP_sleep_interval_requests: 500 # Set this for waiting yt_dlp process
YT_DLP_remove_sponsors_block: ["sponsor", "intro", "outro", "selfpromo", "preview", "filler", "interaction"] # Set this to remove specified segments from the trailer using yt_dlp

Could you please test the new version and provide any feedback on the program's behavior?

Thank you!

TaylanTatli commented 1 month ago

Thanks for quick response. Now It starts searching for trailers correctly, but a new problem appears. If I use TBDB API key, it gives this:

 [ MAIN ] Starting trailer finder. 
     -------------------------------- 
 [ RADARR ] Movie trailer finder started. 
     -------------------------------- 
     -> SCAN Looking for Civil War (2024) trailers 
         -> GET Getting information about 929590 MOVIE 
 [ MAIN ] An error occurred: 
Radarr: 'auth_yt_user' 
Sonarr: 'sonarr_host'  

If I use TBDB Auth key, it gives this:

 [ MAIN ] Starting trailer finder. 
     -------------------------------- 
 [ RADARR ] Movie trailer finder started. 
     -------------------------------- 
     -> SCAN Looking for Civil War (2024) trailers 
         -> GET Getting information about 929590 MOVIE 
 [ TMDB ] 401 - Invalid API key: You must be granted a valid key. 
     -> No trailer is available for Civil War (2024) 

I regenerated my API keys just in case, but it solves nothing. I'm checking my config RN to see if I make anything wrong.

TaylanTatli commented 1 month ago

I set my YouTube account details in config to see if it changes anything, it gives this:

 [ MAIN ] Starting trailer finder. 
     -------------------------------- 
 [ RADARR ] Movie trailer finder started. 
     -------------------------------- 
     -> SCAN Looking for Civil War (2024) trailers 
         -> GET Getting information about 929590 MOVIE 
 [ MAIN ] An error occurred: 
Radarr: 'YT_DLP_remove_spensors_block' 
Sonarr: 'sonarr_host'

EDIT1: There is a mistyping in here: https://github.com/kalibrado/trailer-finder/blob/29ad16655bd222524d96d00a03b2cdf1794f405a/modules/utils.py#L243

I will use like this in config to see if it will fix it.

EDIT2: It solves while giving warning:

 [ MAIN ] Starting trailer finder. 
     -------------------------------- 
 [ RADARR ] Movie trailer finder started. 
     -------------------------------- 
     -> SCAN Looking for Civil War (2024) trailers 
         -> GET Getting information about 929590 MOVIE 
         -> DOWNLOAD Downloading Türkçe Altyazılı Fragman | 26 Nisan'da Sinemalarda trailer from https://www.youtube.com/watch?v=4Aiq3HtY-3g 
WARNING: [youtube] Login with password is not supported for this website. Use --cookies-from-browser or --cookies for the authentication. See  https://github.com/yt-dlp/yt-dlp/wiki/FAQ#how-do-i-pass-cookies-to-yt-dlp  for how to manually pass cookies
kalibrado commented 1 month ago

I fixed the "YT_DLP_remove_spensors_block" problem. For the warning you encountered, I will create a task to look into it in more detail. Thank you for your feedback 🤩!

TaylanTatli commented 1 month ago

I thank you. This was the one of the most wanted thing for me since I started self-hosting but never find anything to suit my needs.