Jump to content

TheMovieDb (TMDB) refuse to work at random time.


McMovies

Recommended Posts

McMovies

for past few week, at random time, tmdb is refusing to scrape.
 if istop for like 1-2 hours and try again it works for few items. and refuse to work.


i can ping/traceroute themoviedb.org without any issues from the terminal of this server, all the time. 
checked all network log, and nothing seems to blocking tmbd. 

can anyone please  suggest how to fix this error ? 

i could be wrong, but seem like it is hitting the APi rate limit. if so is there any way i can use a personal API ?

server log is repeatedly filled with this:-  

2024-01-13 08:15:06.948 Info HttpClient: GET https://api.themoviedb.org/3/configuration?api_key=x_secret1_x
2024-01-13 08:15:07.146 Error HttpClient: Error getting response from https://api.themoviedb.org/3/configuration?api_key=x_secret1_x
	*** Error Report ***
	Version: 4.7.14.0
	Command line: /opt/emby-server/system/EmbyServer.dll -programdata /var/lib/emby -ffdetect /opt/emby-server/bin/ffdetect -ffmpeg /opt/emby-server/bin/ffmpeg -ffprobe /opt/emby-server/bin/ffprobe -restartexitcode 3 -updatepackage emby-server-deb_{version}_arm64.deb
	Operating system: Linux version 6.1.21-v8+ (dom@buildbot) (aarch64-linux-gnu-gcc-8 (Ubuntu/Linaro 8.4.0-3ubuntu1) 8.4.0, GNU ld (GNU Binutils for Ubuntu) 2.34) #1642 SM
	Framework: .NET 6.0.20
	OS/Process: arm64/arm64
	Runtime: opt/emby-server/system/System.Private.CoreLib.dll
	Processor count: 4
	Data path: /var/lib/emby
	Application path: /opt/emby-server/system
	System.Net.Http.HttpRequestException: System.Net.Http.HttpRequestException: The SSL connection could not be established, see inner exception.
	 ---> System.IO.IOException: Unable to read data from the transport connection: Connection reset by peer.
	 ---> System.Net.Sockets.SocketException (104): Connection reset by peer
	   --- End of inner exception stack trace ---
	   at System.Net.Sockets.Socket.AwaitableSocketAsyncEventArgs.ThrowException(SocketError error, CancellationToken cancellationToken)
	   at System.Net.Sockets.Socket.AwaitableSocketAsyncEventArgs.System.Threading.Tasks.Sources.IValueTaskSource<System.Int32>.GetResult(Int16 token)
	   at System.Net.Security.SslStream.<FillHandshakeBufferAsync>g__InternalFillHandshakeBufferAsync|189_0[TIOAdapter](TIOAdapter adap, ValueTask`1 task, Int32 minSize)
	   at System.Net.Security.SslStream.ReceiveBlobAsync[TIOAdapter](TIOAdapter adapter)
	   at System.Net.Security.SslStream.ForceAuthenticationAsync[TIOAdapter](TIOAdapter adapter, Boolean receiveFirst, Byte[] reAuthenticationData, Boolean isApm)
	   at System.Net.Http.ConnectHelper.EstablishSslConnectionAsync(SslClientAuthenticationOptions sslOptions, HttpRequestMessage request, Boolean async, Stream stream, CancellationToken cancellationToken)
	   --- End of inner exception stack trace ---
	   at System.Net.Http.ConnectHelper.EstablishSslConnectionAsync(SslClientAuthenticationOptions sslOptions, HttpRequestMessage request, Boolean async, Stream stream, CancellationToken cancellationToken)
	   at System.Net.Http.HttpConnectionPool.ConnectAsync(HttpRequestMessage request, Boolean async, CancellationToken cancellationToken)
	   at System.Net.Http.HttpConnectionPool.CreateHttp11ConnectionAsync(HttpRequestMessage request, Boolean async, CancellationToken cancellationToken)
	   at System.Net.Http.HttpConnectionPool.AddHttp11ConnectionAsync(HttpRequestMessage request)
	   at System.Threading.Tasks.TaskCompletionSourceWithCancellation`1.WaitWithCancellationAsync(CancellationToken cancellationToken)
	   at System.Net.Http.HttpConnectionPool.GetHttp11ConnectionAsync(HttpRequestMessage request, Boolean async, CancellationToken cancellationToken)
	   at System.Net.Http.HttpConnectionPool.SendWithVersionDetectionAndRetryAsync(HttpRequestMessage request, Boolean async, Boolean doRequestAuth, CancellationToken cancellationToken)
	   at System.Net.Http.RedirectHandler.SendAsync(HttpRequestMessage request, Boolean async, CancellationToken cancellationToken)
	   at System.Net.Http.DecompressionHandler.SendAsync(HttpRequestMessage request, Boolean async, CancellationToken cancellationToken)
	   at System.Net.Http.HttpClient.<SendAsync>g__Core|83_0(HttpRequestMessage request, HttpCompletionOption completionOption, CancellationTokenSource cts, Boolean disposeCts, CancellationTokenSource pendingRequestsCts, CancellationToken originalCancellationToken)
	   at Emby.Server.Implementations.HttpClientManager.CoreHttpClientManager.SendAsyncInternal(HttpRequestOptions options, String httpMethod)
	Source: System.Net.Http
	TargetSite: Void MoveNext()
	InnerException: System.IO.IOException: Unable to read data from the transport connection: Connection reset by peer.
	Source: System.Net.Sockets
	TargetSite: Void ThrowException(System.Net.Sockets.SocketError, System.Threading.CancellationToken)
	   at System.Net.Sockets.Socket.AwaitableSocketAsyncEventArgs.ThrowException(SocketError error, CancellationToken cancellationToken)
	   at System.Net.Sockets.Socket.AwaitableSocketAsyncEventArgs.System.Threading.Tasks.Sources.IValueTaskSource<System.Int32>.GetResult(Int16 token)
	   at System.Net.Security.SslStream.<FillHandshakeBufferAsync>g__InternalFillHandshakeBufferAsync|189_0[TIOAdapter](TIOAdapter adap, ValueTask`1 task, Int32 minSize)
	   at System.Net.Security.SslStream.ReceiveBlobAsync[TIOAdapter](TIOAdapter adapter)
	   at System.Net.Security.SslStream.ForceAuthenticationAsync[TIOAdapter](TIOAdapter adapter, Boolean receiveFirst, Byte[] reAuthenticationData, Boolean isApm)
	   at System.Net.Http.ConnectHelper.EstablishSslConnectionAsync(SslClientAuthenticationOptions sslOptions, HttpRequestMessage request, Boolean async, Stream stream, CancellationToken cancellationToken)
	InnerException: System.Net.Sockets.SocketException: Connection reset by peer
	Source: 
	TargetSite: 
	
2024-01-13 08:15:07.176 Error App: Error in TheMovieDb
	*** Error Report ***
	Version: 4.7.14.0
	Command line: /opt/emby-server/system/EmbyServer.dll -programdata /var/lib/emby -ffdetect /opt/emby-server/bin/ffdetect -ffmpeg /opt/emby-server/bin/ffmpeg -ffprobe /opt/emby-server/bin/ffprobe -restartexitcode 3 -updatepackage emby-server-deb_{version}_arm64.deb
	Operating system: Linux version 6.1.21-v8+ (dom@buildbot) (aarch64-linux-gnu-gcc-8 (Ubuntu/Linaro 8.4.0-3ubuntu1) 8.4.0, GNU ld (GNU Binutils for Ubuntu) 2.34) #1642 SM
	Framework: .NET 6.0.20
	OS/Process: arm64/arm64
	Runtime: opt/emby-server/system/System.Private.CoreLib.dll
	Processor count: 4
	Data path: /var/lib/emby
	Application path: /opt/emby-server/system
	System.Net.Http.HttpRequestException: System.Net.Http.HttpRequestException: The SSL connection could not be established, see inner exception.
	 ---> System.IO.IOException: Unable to read data from the transport connection: Connection reset by peer.
	 ---> System.Net.Sockets.SocketException (104): Connection reset by peer
	   --- End of inner exception stack trace ---
	   at System.Net.Sockets.Socket.AwaitableSocketAsyncEventArgs.ThrowException(SocketError error, CancellationToken cancellationToken)
	   at System.Net.Sockets.Socket.AwaitableSocketAsyncEventArgs.System.Threading.Tasks.Sources.IValueTaskSource<System.Int32>.GetResult(Int16 token)
	   at System.Net.Security.SslStream.<FillHandshakeBufferAsync>g__InternalFillHandshakeBufferAsync|189_0[TIOAdapter](TIOAdapter adap, ValueTask`1 task, Int32 minSize)
	   at System.Net.Security.SslStream.ReceiveBlobAsync[TIOAdapter](TIOAdapter adapter)
	   at System.Net.Security.SslStream.ForceAuthenticationAsync[TIOAdapter](TIOAdapter adapter, Boolean receiveFirst, Byte[] reAuthenticationData, Boolean isApm)
	   at System.Net.Http.ConnectHelper.EstablishSslConnectionAsync(SslClientAuthenticationOptions sslOptions, HttpRequestMessage request, Boolean async, Stream stream, CancellationToken cancellationToken)
	   --- End of inner exception stack trace ---
	   at Emby.Server.Implementations.HttpClientManager.CoreHttpClientManager.SendAsyncInternal(HttpRequestOptions options, String httpMethod)
	   at Emby.Server.Implementations.HttpClientManager.CoreHttpClientManager.SendAsync(HttpRequestOptions options, String httpMethod)
	   at MovieDb.MovieDbProviderBase.GetMovieDbResponse(HttpRequestOptions options)
	   at MovieDb.MovieDbProviderBase.GetTmdbSettings(CancellationToken cancellationToken)
	   at MovieDb.GenericMovieDbInfo`1.GetMetadata(ItemLookupInfo itemId, CancellationToken cancellationToken)
	   at Emby.Providers.Manager.MetadataService`2.ExecuteRemoteProviders(MetadataResult`1 temp, LibraryOptions libraryOptions, String logName, TIdType id, IEnumerable`1 providers, MetadataRefreshOptions options, CancellationToken cancellationToken)
	Source: System.Net.Http
	TargetSite: Void MoveNext()
	InnerException: System.IO.IOException: Unable to read data from the transport connection: Connection reset by peer.
	Source: System.Net.Sockets
	TargetSite: Void ThrowException(System.Net.Sockets.SocketError, System.Threading.CancellationToken)
	   at System.Net.Sockets.Socket.AwaitableSocketAsyncEventArgs.ThrowException(SocketError error, CancellationToken cancellationToken)
	   at System.Net.Sockets.Socket.AwaitableSocketAsyncEventArgs.System.Threading.Tasks.Sources.IValueTaskSource<System.Int32>.GetResult(Int16 token)
	   at System.Net.Security.SslStream.<FillHandshakeBufferAsync>g__InternalFillHandshakeBufferAsync|189_0[TIOAdapter](TIOAdapter adap, ValueTask`1 task, Int32 minSize)
	   at System.Net.Security.SslStream.ReceiveBlobAsync[TIOAdapter](TIOAdapter adapter)
	   at System.Net.Security.SslStream.ForceAuthenticationAsync[TIOAdapter](TIOAdapter adapter, Boolean receiveFirst, Byte[] reAuthenticationData, Boolean isApm)
	   at System.Net.Http.ConnectHelper.EstablishSslConnectionAsync(SslClientAuthenticationOptions sslOptions, HttpRequestMessage request, Boolean async, Stream stream, CancellationToken cancellationToken)
	InnerException: System.Net.Sockets.SocketException: Connection reset by peer
	Source: 
	TargetSite: 
	
2024-01-13 08:15:07.256 Info HttpClient: GET https://api.themoviedb.org/3/configuration?api_key=x_secret1_x
2024-01-13 08:15:07.566 Error HttpClient: Error getting response from https://api.themoviedb.org/3/configuration?api_key=x_secret1_x
	*** Error Report ***
	Version: 4.7.14.0

Thanks in advance. 

Link to comment
Share on other sites

Hi, yes I would give it a try again later and see if it resolves itself.

Link to comment
Share on other sites

McMovies

yes.
sometime it works sometime it doesn't.  very unpredictable. 
used TVDB for some time, but reverted back to TMDB again. (i always get my images in Fanart, so no issues in images). 

@Luke@GrimReaper, not sure i create a new thread to report TVDB bugs, but for a quick report im putting it here-
i discovered something the way metadata is grabbed from TVDB, they have lots of unwanted garbage section under "Other site"  and are liked to lots of unwanted data like twitter, linkedin, facebook instagram, reddit and what not. most of them has two lines, one under <uniqueid> tag followed by <Social_media_site_name>, tag. also to writes some random redundant tag which i dont think emby reads it. 

Few instances i discovered few links are redirecting to illegal streaming as well.  like multiple links pointing to pirated movie links in youtube in the name of trailer. .

Latest example- https://thetvdb.com/movies/kitbag , this has pirate streams linked as well under reddit tags.

Is it possible to grab only the metadata we actually use in emby or actually usable and keep our nfo clean?
image.thumb.png.6c863565bba2ab182ac83860f4663378.png

Secondly, TVDB metadata doesn't respect our country setting for  <mpaa> tags, mentioned in library settings. for me God knows why its grabbing movie rating from Singapore region, and displaying SG-18,M18, etc instead of "R".

Edited by McMovies
--
Link to comment
Share on other sites

Quote

Secondly, TVDB metadata doesn't respect our country setting for  <mpaa> tags, mentioned in library settings. for me God knows why its grabbing movie rating from Singapore region, and displaying SG-18,M18, etc instead of "R".

Hi there, can you please provide a specific example? Did you check the rating on the MovieDb website?

Link to comment
Share on other sites

McMovies
12 hours ago, Luke said:

Hi there, can you please provide a specific example? Did you check the rating on the MovieDb website?

there were few examples, when i made TVDB primary and added few new content. (not able to recall all as i manually edited the rating afterwords).
if i can remember this - https://thetvdb.com/movies/la-sociedad-de-la-nieve  its shown me Singapore rating18, and not "R".

-------
back to TMDB, its still refusing to connect.  some SSL issue man be... 

Application path: /opt/emby-server/system
	System.Net.Http.HttpRequestException: System.Net.Http.HttpRequestException: The SSL connection could not be established, see inner exception.
	 ---> System.IO.IOException: Unable to read data from the transport connection: Connection reset by peer.

 

Link to comment
Share on other sites

Assuming you don't have a vpn that might be interfering with the request, it could just be a temporary issue on moviedb's side.

Link to comment
Share on other sites

  • 1 month later...
McMovies

@Luke any update on this:

it seem now if completely broken. getting all metadata from tvdb instead. here is the log again: 

2024-02-19 08:15:23.852 Error App: Error in TheMovieDb
	*** Error Report ***
	Version: 4.7.14.0
	Command line: /opt/emby-server/system/EmbyServer.dll -programdata /var/lib/emby -ffdetect /opt/emby-server/bin/ffdetect -ffmpeg /opt/emby-server/bin/ffmpeg -ffprobe /opt/emby-server/bin/ffprobe -restartexitcode 3 -updatepackage emby-server-deb_{version}_arm64.deb
	Operating system: Linux version 6.1.21-v8+ (dom@buildbot) (aarch64-linux-gnu-gcc-8 (Ubuntu/Linaro 8.4.0-3ubuntu1) 8.4.0, GNU ld (GNU Binutils for Ubuntu) 2.34) #1642 SM
	Framework: .NET 6.0.20
	OS/Process: arm64/arm64
	Runtime: opt/emby-server/system/System.Private.CoreLib.dll
	Processor count: 4
	Data path: /var/lib/emby
	Application path: /opt/emby-server/system
	System.Net.Http.HttpRequestException: System.Net.Http.HttpRequestException: The SSL connection could not be established, see inner exception.
	 ---> System.IO.IOException: Unable to read data from the transport connection: Connection reset by peer.
	 ---> System.Net.Sockets.SocketException (104): Connection reset by peer
	   --- End of inner exception stack trace ---
	   at System.Net.Sockets.Socket.AwaitableSocketAsyncEventArgs.ThrowException(SocketError error, CancellationToken cancellationToken)
	   at System.Net.Sockets.Socket.AwaitableSocketAsyncEventArgs.System.Threading.Tasks.Sources.IValueTaskSource<System.Int32>.GetResult(Int16 token)
	   at System.Net.Security.SslStream.<FillHandshakeBufferAsync>g__InternalFillHandshakeBufferAsync|189_0[TIOAdapter](TIOAdapter adap, ValueTask`1 task, Int32 minSize)
	   at System.Net.Security.SslStream.ReceiveBlobAsync[TIOAdapter](TIOAdapter adapter)
	   at System.Net.Security.SslStream.ForceAuthenticationAsync[TIOAdapter](TIOAdapter adapter, Boolean receiveFirst, Byte[] reAuthenticationData, Boolean isApm)
	   at System.Net.Http.ConnectHelper.EstablishSslConnectionAsync(SslClientAuthenticationOptions sslOptions, HttpRequestMessage request, Boolean async, Stream stream, CancellationToken cancellationToken)
	   --- End of inner exception stack trace ---
	   at Emby.Server.Implementations.HttpClientManager.CoreHttpClientManager.SendAsyncInternal(HttpRequestOptions options, String httpMethod)
	   at Emby.Server.Implementations.HttpClientManager.CoreHttpClientManager.SendAsync(HttpRequestOptions options, String httpMethod)
	   at MovieDb.MovieDbProviderBase.GetMovieDbResponse(HttpRequestOptions options)
	   at MovieDb.MovieDbProviderBase.GetTmdbLanguages(CancellationToken cancellationToken)
	   at MovieDb.MovieDbSeasonProvider.FetchMainResult(String id, Int32 seasonNumber, String language, String preferredMetadataCountry, CancellationToken cancellationToken)
	   at MovieDb.MovieDbSeasonProvider.EnsureSeasonInfo(String tmdbId, Int32 seasonNumber, String language, String preferredMetadataCountry, IDirectoryService directoryService, CancellationToken cancellationToken)
	   at MovieDb.MovieDbSeasonProvider.GetMetadata(RemoteMetadataFetchOptions`1 options, CancellationToken cancellationToken)
	   at Emby.Providers.Manager.MetadataService`2.ExecuteRemoteProviders(MetadataResult`1 temp, LibraryOptions libraryOptions, String logName, TIdType id, IEnumerable`1 providers, MetadataRefreshOptions options, CancellationToken cancellationToken)
	Source: System.Net.Http
	TargetSite: Void MoveNext()
	InnerException: System.IO.IOException: Unable to read data from the transport connection: Connection reset by peer.
	Source: System.Net.Sockets
	TargetSite: Void ThrowException(System.Net.Sockets.SocketError, System.Threading.CancellationToken)
	   at System.Net.Sockets.Socket.AwaitableSocketAsyncEventArgs.ThrowException(SocketError error, CancellationToken cancellationToken)
	   at System.Net.Sockets.Socket.AwaitableSocketAsyncEventArgs.System.Threading.Tasks.Sources.IValueTaskSource<System.Int32>.GetResult(Int16 token)
	   at System.Net.Security.SslStream.<FillHandshakeBufferAsync>g__InternalFillHandshakeBufferAsync|189_0[TIOAdapter](TIOAdapter adap, ValueTask`1 task, Int32 minSize)
	   at System.Net.Security.SslStream.ReceiveBlobAsync[TIOAdapter](TIOAdapter adapter)
	   at System.Net.Security.SslStream.ForceAuthenticationAsync[TIOAdapter](TIOAdapter adapter, Boolean receiveFirst, Byte[] reAuthenticationData, Boolean isApm)
	   at System.Net.Http.ConnectHelper.EstablishSslConnectionAsync(SslClientAuthenticationOptions sslOptions, HttpRequestMessage request, Boolean async, Stream stream, CancellationToken cancellationToken)
	InnerException: System.Net.Sockets.SocketException: Connection reset by peer
	Source: 
	TargetSite: 

  

Link to comment
Share on other sites

Hi there, please attach the complete emby server log. Thanks.

Link to comment
Share on other sites

  • 1 month later...
Happy2Play

Though it only related to timing out but do you by change use IPv6?

On 1/14/2024 at 12:48 AM, McMovies said:

Secondly, TVDB metadata doesn't respect our country setting for  <mpaa> tags, mentioned in library settings. for me God knows why its grabbing movie rating from Singapore region, and displaying SG-18,M18, etc instead of "R".

What is your library or item language set to?  So I can test this as I know where the issue is for TV but have not really tested any movies.

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...