pymedusa / Medusa

Automatic Video Library Manager for TV Shows. It watches for new episodes of your favorite shows, and when they are posted it does its magic.
https://pymedusa.com
GNU General Public License v3.0
1.8k stars 276 forks source link

New to medusa coming from sickchill #7545

Closed papampi closed 4 years ago

papampi commented 4 years ago

Hi guys, Installd on QNAP with sherpa script with no problems at all. But ...

Tried to restore sickchill backup with no luck, all the fields shown empty and no shows at all, so stopped medusa removed all .db and start it to go clean. I saw many tvmaze errors:

Could not get tvmaze externals. Cause: ConnectTimeout(MaxRetryError("HTTPConnectionPool(host='api.tvmaze.com', port=80): Max retries exceeded with url: /lookup/shows?imdb=tt10234362 (Caused by ConnectTimeoutError(<urllib3.connection.HTTPConnection object at 0x7f5550015360>, 'Connection to api.tvmaze.com timed out. (connect timeout=30)'))",),)

So set the indexer to tvdbv2 restarted medusa but the tvmaze error still pops up and It looks like its not scanning folders or its too slow

Medusa Info: Branch: masterCommit: d0c136d7a528a471b51676140bd35d24d97f65c6Version: 0.3.9Database: 44.14
Python Version: 2.7.16 (default, Oct 02 2019, 11:13:20) [GCC 7.4.0]
SSL Version: OpenSSL 1.1.1d 10 Sep 2019
OS: Linux-4.14.24-qnap-x86_64-with-glibc2.2.5
Locale: en_US.UTF-8

**Debug logs:

``` 2020-01-04 16:13:38 DEBUG SHOWQUEUE-ADD :: [d0c136d] 364106: Loading show info from IMDb with ID: tt10234362 2020-01-04 16:13:38 DEBUG SHOWQUEUE-ADD :: [d0c136d] Retrieving show info from IMDb 2020-01-04 16:13:38 INFO SHOWQUEUE-ADD :: [d0c136d] Setting all previously aired episodes to the specified status: Skipped 2020-01-04 16:13:38 DEBUG SHOWQUEUE-ADD :: [d0c136d] TVDBv2 364106: Setting location: /share/CACHEDEV8_DATA/TV_Series/Avenue 5 2020-01-04 16:13:38 DEBUG SHOWQUEUE-ADD :: [d0c136d] Transaction with 2 queries executed 2020-01-04 16:12:40 DEBUG Thread-1 :: [d0c136d] "/opt/bin/git" ls-remote --heads origin : returned successful 2020-01-04 16:12:28 DEBUG Thread-1 :: [d0c136d] Executing "/opt/bin/git" ls-remote --heads origin with your shell in /share/CACHEDEV1_DATA/.qpkg/OMedusa/OMedusa 2020-01-04 16:12:28 DEBUG Thread-1 :: [d0c136d] "/opt/bin/git" symbolic-ref -q HEAD : returned successful 2020-01-04 16:12:28 DEBUG Thread-1 :: [d0c136d] Executing "/opt/bin/git" symbolic-ref -q HEAD with your shell in /share/CACHEDEV1_DATA/.qpkg/OMedusa/OMedusa 2020-01-04 16:12:28 DEBUG Thread-1 :: [d0c136d] "/opt/bin/git" config remote.origin.pushurl https://github.com/pymedusa/Medusa.git : returned successful 2020-01-04 16:12:28 DEBUG Thread-1 :: [d0c136d] Executing "/opt/bin/git" config remote.origin.pushurl https://github.com/pymedusa/Medusa.git with your shell in /share/CACHEDEV1_DATA/.qpkg/OMedusa/OMedusa 2020-01-04 16:12:28 DEBUG Thread-1 :: [d0c136d] "/opt/bin/git" config remote.origin.url https://github.com/pymedusa/Medusa.git : returned successful 2020-01-04 16:12:28 DEBUG Thread-1 :: [d0c136d] Executing "/opt/bin/git" config remote.origin.url https://github.com/pymedusa/Medusa.git with your shell in /share/CACHEDEV1_DATA/.qpkg/OMedusa/OMedusa 2020-01-04 16:11:30 WARNING SHOWQUEUE-ADD :: [d0c136d] Could not get tvmaze externals. Cause: ConnectTimeout(MaxRetryError("HTTPConnectionPool(host='api.tvmaze.com', port=80): Max retries exceeded with url: /lookup/shows?imdb=tt10234362 (Caused by ConnectTimeoutError(, 'Connection to api.tvmaze.com timed out. (connect timeout=30)'))",),) 2020-01-04 16:08:44 INFO POSTPROCESSOR :: [d0c136d] Post-processing completed. 2020-01-04 16:08:44 DEBUG POSTPROCESSOR :: [d0c136d] No processable items found in folder: /share/CACHEDEV1_DATA/Download/torrents/completed/series 2020-01-04 16:08:44 DEBUG POSTPROCESSOR :: [d0c136d] Processing path: /share/Download/torrents/completed/series 2020-01-04 16:08:44 DEBUG POSTPROCESSOR :: [d0c136d] Starting new thread: POSTPROCESSOR 2020-01-04 16:08:26 WARNING SHOWQUEUE-ADD :: [d0c136d] Could not get tvmaze externals. Cause: ConnectTimeout(MaxRetryError("HTTPConnectionPool(host='api.tvmaze.com', port=80): Max retries exceeded with url: /lookup/shows?thetvdb=364106 (Caused by ConnectTimeoutError(, 'Connection to api.tvmaze.com timed out. (connect timeout=30)'))",),) 2020-01-04 16:05:23 DEBUG SHOWQUEUE-ADD :: [d0c136d] Trying other indexer: TVmaze get_id_by_external 2020-01-04 16:05:23 DEBUG SHOWQUEUE-ADD :: [d0c136d] 364106: Loading show info from TVDBv2 2020-01-04 16:05:23 INFO SHOWQUEUE-ADD :: [d0c136d] 364106: Unable to find the show in the database 2020-01-04 16:05:23 DEBUG SHOWQUEUE-ADD :: [d0c136d] 364106: Loading show info from database 2020-01-04 16:03:12 WARNING SHOWQUEUE-ADD :: [d0c136d] Could not get tvmaze externals. Cause: ConnectTimeout(MaxRetryError("HTTPConnectionPool(host='api.tvmaze.com', port=80): Max retries exceeded with url: /lookup/shows?imdb=tt10234362 (Caused by ConnectTimeoutError(, 'Connection to api.tvmaze.com timed out. (connect timeout=30)'))",),) 2020-01-04 16:00:22 DEBUG APIv2-Thread-5 :: [d0c136d] Using custom UI: 2020-01-04 16:00:22 DEBUG APIv2-Thread-5 :: [d0c136d] User-Agent: Medusa/0.3.9 (Linux; 4.14.24-qnap; ba2578a3-2eed-11ea-9ebd-00089bef61c6) 2020-01-04 16:00:22 DEBUG APIv2-Thread-5 :: [d0c136d] GET URL: https://api.thetvdb.com/search/series?name=marvel%27s+hawkeye [Status: 200] 2020-01-04 16:00:22 DEBUG APIv2-Thread-5 :: [d0c136d] Searching for show: marvel's hawkeye 2020-01-04 16:00:22 DEBUG APIv2-Thread-5 :: [d0c136d] Searching for show with search term(s): [u"Marvel's Hawkeye"] on indexer: tvdb 2020-01-04 16:00:10 DEBUG APIv2-Thread-2 :: [d0c136d] Using custom UI: 2020-01-04 16:00:10 DEBUG APIv2-Thread-2 :: [d0c136d] User-Agent: Medusa/0.3.9 (Linux; 4.14.24-qnap; ba2578a3-2eed-11ea-9ebd-00089bef61c6) 2020-01-04 16:00:10 DEBUG APIv2-Thread-2 :: [d0c136d] GET URL: https://api.thetvdb.com/search/series?name=haunting+of+hill+house [Status: 200] 2020-01-04 16:00:10 DEBUG APIv2-Thread-2 :: [d0c136d] Searching for show: haunting of hill house 2020-01-04 16:00:10 DEBUG APIv2-Thread-2 :: [d0c136d] Using custom UI: 2020-01-04 16:00:10 DEBUG APIv2-Thread-2 :: [d0c136d] User-Agent: Medusa/0.3.9 (Linux; 4.14.24-qnap; ba2578a3-2eed-11ea-9ebd-00089bef61c6) 2020-01-04 16:00:10 DEBUG APIv2-Thread-2 :: [d0c136d] GET URL: https://api.thetvdb.com/search/series?name=the+haunting+of+hill+house [Status: 200] 2020-01-04 16:00:09 DEBUG APIv2-Thread-2 :: [d0c136d] Searching for show: the haunting of hill house 2020-01-04 16:00:09 DEBUG APIv2-Thread-2 :: [d0c136d] Searching for show with search term(s): [u'The Haunting of Hill House', u'Haunting of Hill House'] on indexer: tvdb 2020-01-04 16:00:08 DEBUG SHOWQUEUE-ADD :: [d0c136d] Trying other indexer: TVmaze get_id_by_external 2020-01-04 16:00:08 DEBUG SHOWQUEUE-ADD :: [d0c136d] User-Agent: Medusa/0.3.9 (Linux; 4.14.24-qnap; ba2578a3-2eed-11ea-9ebd-00089bef61c6) 2020-01-04 16:00:08 DEBUG SHOWQUEUE-ADD :: [d0c136d] GET URL: https://api.thetvdb.com/series/364106/episodes/query?page=1 [Status: 200] 2020-01-04 16:00:08 DEBUG SHOWQUEUE-ADD :: [d0c136d] Getting all episodes of 364106 2020-01-04 16:00:08 DEBUG SHOWQUEUE-ADD :: [d0c136d] User-Agent: Medusa/0.3.9 (Linux; 4.14.24-qnap; ba2578a3-2eed-11ea-9ebd-00089bef61c6) 2020-01-04 16:00:08 DEBUG SHOWQUEUE-ADD :: [d0c136d] GET URL: https://api.thetvdb.com/series/364106 [Status: 200] 2020-01-04 16:00:06 DEBUG APIv2-Thread-7 :: [d0c136d] Using custom UI: 2020-01-04 16:00:06 DEBUG APIv2-Thread-7 :: [d0c136d] User-Agent: Medusa/0.3.9 (Linux; 4.14.24-qnap; ba2578a3-2eed-11ea-9ebd-00089bef61c6) 2020-01-04 16:00:06 DEBUG APIv2-Thread-7 :: [d0c136d] GET URL: https://api.thetvdb.com/search/series?name=spinning+out [Status: 200] 2020-01-04 15:59:59 DEBUG APIv2-Thread-7 :: [d0c136d] Searching for show: spinning out 2020-01-04 15:59:59 DEBUG APIv2-Thread-7 :: [d0c136d] Searching for show with search term(s): [u'Spinning Out'] on indexer: tvdb 2020-01-04 15:59:58 DEBUG SHOWQUEUE-ADD :: [d0c136d] Getting all show data for 364106 2020-01-04 15:59:58 DEBUG SHOWQUEUE-ADD :: [d0c136d] Getting all series data for 364106 2020-01-04 15:59:58 DEBUG SHOWQUEUE-ADD :: [d0c136d] Configured language en override show language of en 2020-01-04 15:59:58 INFO SHOWQUEUE-ADD :: [d0c136d] TVDBv2: {u'session': , u'cache': u'/share/CACHEDEV1_DATA/.qpkg/OMedusa/config/cache/indexers/TVDBv2', u'language': u'en', u'use_zip': True, u'proxy': u'http://192.168.1.251:3128'} 2020-01-04 15:59:58 INFO SHOWQUEUE-ADD :: [d0c136d] Starting to add show by show_dir: /share/CACHEDEV8_DATA/TV_Series/Avenue 5 2020-01-04 15:59:50 DEBUG APIv2-Thread-6 :: [d0c136d] Cannot load the KODI metadata file from /share/CACHEDEV6_DATA/Family_TV_Series/Marvel's Hawkeye/tvshow.nfo, it does not exist 2020-01-04 15:59:50 DEBUG APIv2-Thread-6 :: [d0c136d] Cannot load the KODI 12+ metadata file from /share/CACHEDEV6_DATA/Family_TV_Series/Marvel's Hawkeye/tvshow.nfo, it does not exist 2020-01-04 15:59:50 DEBUG APIv2-Thread-6 :: [d0c136d] Loading show info from KODI 12+ metadata file in /share/CACHEDEV6_DATA/Family_TV_Series/Prank Encounters 2020-01-04 15:59:50 DEBUG APIv2-Thread-6 :: [d0c136d] Loading show info from KODI 12+ metadata file in /share/CACHEDEV6_DATA/Family_TV_Series/The Umbrella Academy 2020-01-04 15:59:50 DEBUG APIv2-Thread-6 :: [d0c136d] Loading show info from KODI 12+ metadata file in /share/CACHEDEV6_DATA/Family_TV_Series/The Neighborhood 2020-01-04 15:59:50 DEBUG APIv2-Thread-6 :: [d0c136d] Loading show info from KODI 12+ metadata file in /share/CACHEDEV6_DATA/Family_TV_Series/The Goldbergs (2013) 2020-01-04 15:59:50 DEBUG APIv2-Thread-6 :: [d0c136d] Loading show info from KODI 12+ metadata file in /share/CACHEDEV6_DATA/Family_TV_Series/The Flash (2014) 2020-01-04 15:59:50 DEBUG APIv2-Thread-6 :: [d0c136d] Loading show info from KODI 12+ metadata file in /share/CACHEDEV6_DATA/Family_TV_Series/The Dark Crystal Age of Resistance 2020-01-04 15:59:50 DEBUG APIv2-Thread-6 :: [d0c136d] Loading show info from KODI 12+ metadata file in /share/CACHEDEV6_DATA/Family_TV_Series/Team Kaylie 2020-01-04 15:59:50 DEBUG APIv2-Thread-6 :: [d0c136d] Loading show info from KODI 12+ metadata file in /share/CACHEDEV6_DATA/Family_TV_Series/Supergirl 2020-01-04 15:59:50 DEBUG APIv2-Thread-6 :: [d0c136d] Loading show info from KODI 12+ metadata file in /share/CACHEDEV6_DATA/Family_TV_Series/Stranger Things 2020-01-04 15:59:50 DEBUG APIv2-Thread-6 :: [d0c136d] Loading show info from KODI 12+ metadata file in /share/CACHEDEV6_DATA/Family_TV_Series/Single Parents 2020-01-04 15:59:50 DEBUG APIv2-Thread-6 :: [d0c136d] Loading show info from KODI 12+ metadata file in /share/CACHEDEV6_DATA/Family_TV_Series/Schooled 2020-01-04 15:59:50 DEBUG APIv2-Thread-6 :: [d0c136d] Loading show info from KODI 12+ metadata file in /share/CACHEDEV6_DATA/Family_TV_Series/Prince of Peoria 2020-01-04 15:59:50 DEBUG APIv2-Thread-6 :: [d0c136d] Loading show info from KODI 12+ metadata file in /share/CACHEDEV6_DATA/Family_TV_Series/Modern Family 2020-01-04 15:59:50 DEBUG APIv2-Thread-6 :: [d0c136d] Loading show info from KODI 12+ metadata file in /share/CACHEDEV6_DATA/Family_TV_Series/mixed-ish 2020-01-04 15:59:50 DEBUG APIv2-Thread-6 :: [d0c136d] Loading show info from KODI 12+ metadata file in /share/CACHEDEV6_DATA/Family_TV_Series/Marvels Agents of S.H.I.E.L.D 2020-01-04 15:59:50 DEBUG APIv2-Thread-6 :: [d0c136d] Loading show info from KODI 12+ metadata file in /share/CACHEDEV6_DATA/Family_TV_Series/Man with a Plan 2020-01-04 15:59:50 DEBUG APIv2-Thread-6 :: [d0c136d] Loading show info from KODI 12+ metadata file in /share/CACHEDEV6_DATA/Family_TV_Series/Lost in Space (2018) 2020-01-04 15:59:50 DEBUG APIv2-Thread-6 :: [d0c136d] Loading show info from KODI 12+ metadata file in /share/CACHEDEV6_DATA/Family_TV_Series/Daybreak (2019)```

Additional context Add any other context about the problem here.

papampi commented 4 years ago

So its been 2 hours since I started the "Add existing shows" and it only added 2 shows, with this pace it's going to take months to complete it.

Any helps?

medariox commented 4 years ago

Looks like you are having connectivity issues to TVmaze. Have you tried renaming the sick* database from sickbeard.db to main.db?

papampi commented 4 years ago

I removed all *.db files after failed restore from web to start fresh.

papampi commented 4 years ago

I have all old sickchill files, is it better to copy them all? Which ones should be copied and renamed?

Edit: Thank for the tip, just coped/renamed sickbeard.db and all looks ok.

medariox commented 4 years ago

If you are having connectivity issues, adding many shows can be a pain. That's why I suggested to copy sickbeard.db and rename it to main.db. It usually works that way. You can try to copy over the config.ini as well if you want to keep the settings.

Glad it's working for you now, closing the issue.

papampi commented 4 years ago

Already done the settings manually, but why there is connectivity issue to tvmaze? I can open web and api links with no problems. Looks like same issue posted in https://github.com/pymedusa/Medusa/issues/7240

medariox commented 4 years ago

Can you reach http://api.tvmaze.com/singlesearch/shows?q=girls&embed=episodes from the same machine Medusa is installed on? It could be a temporary issue on their end or maybe they are limiting you or your country.

papampi commented 4 years ago

I can reach it from the machine I have my proxy on it, but looks like medusa not passing tvmaze through my proxy. I cant see it shows in proxy logs either

papampi commented 4 years ago

Here is the proxy log when I try to reach it from any machines on my local network through proxy:

CONNECT   Jan 04 17:58:38 [29817]: Connect (file descriptor 6): 192.168.1.251 [192.168.1.251]
CONNECT   Jan 04 17:58:38 [29817]: Request (file descriptor 6): GET http://api.tvmaze.com/singlesearch/shows?q=girls&embed=episodes HTTP/1.1
INFO      Jan 04 17:58:38 [29817]: No upstream proxy for api.tvmaze.com
CONNECT   Jan 04 17:58:38 [29817]: Established connection to host "api.tvmaze.com" using file descriptor 7.

But see no requests in logs from medusa

papampi commented 4 years ago

It connects to the tvdb via proxy:

2020-01-04 17:57:33 INFO    SHOWQUEUE-ADD :: [d0c136d] TVDBv2: {u'session': <medusa.session.core.MedusaSession object at 0x4d1a200>, u'cache': u'/share/CACHEDEV1_DATA/.qpkg/OMedusa/config/cache/indexers/TVDBv2', u'language': u'en', u'use_zip': True, u'proxy': u'http://192.168.1.251:3128'}

Buy looks like no proxy for tvmaze:

2020-01-04 18:00:48 WARNING SHOWQUEUE-ADD :: [d0c136d] Could not get tvmaze externals. Cause: ConnectTimeout(MaxRetryError("HTTPConnectionPool(host='api.tvmaze.com', port=80): Max retries exceeded with url: /lookup/shows?imdb=tt6156584 (Caused by ConnectTimeoutError(<urllib3.connection.HTTPConnection object at 0x7f55b01708e0>, 'Connection to api.tvmaze.com timed out. (connect timeout=30)'))",),)
papampi commented 4 years ago

@medariox Should I open a new ticket for tvmaze proxy or you will re-open this one?

medariox commented 4 years ago

I think it's just that one method that doesn't use the proxy. Can you try adding a random show with tvmaze and see if it goes through the proxy?

papampi commented 4 years ago

Looks like not passing through proxy and not showing on my proxy logs

2020-01-04 18:18:26 INFO    APIv2-Thread-6 :: [d0c136d] Error searching for show. term(s): [u'girls'] indexer: tvmaze error: Show search failed in getting a result with error: ConnectionError()
2020-01-04 18:18:21 DEBUG   APIv2-Thread-6 :: [d0c136d] Searching for show girls
2020-01-04 18:18:21 DEBUG   APIv2-Thread-6 :: [d0c136d] Searching for show with search term(s): [u'girls'] on indexer: tvmaze
2020-01-04 18:17:32 DEBUG   APIv2-Thread-3 :: [d0c136d] Searching for show girls
2020-01-04 18:17:32 DEBUG   APIv2-Thread-3 :: [d0c136d] Searching for show with search term(s): [u'girls'] on indexer: tvmaze
papampi commented 4 years ago

TMDB doing the same:

2020-01-04 18:21:05 WARNING SHOWQUEUE-ADD :: [d0c136d] Indexer TMDB is unavailable at this time: HTTPSConnectionPool(host='api.themoviedb.org', port=443): Max retries exceeded with url: /3/configuration?api_key=edc5f123313769de83a71e157758030b (Caused by NewConnectionError('<urllib3.connection.VerifiedHTTPSConnection object at 0x7f55b0206a40>: Failed to establish a new connection: [Errno 110] Connection timed out',))
papampi commented 4 years ago

It looks like in advanced settings it mentioned that only thetvdb uses proxy

"use proxy host for connecting to indexers (thetvdb)"