rmrector / script.artwork.dump

MIT License
5 stars 1 forks source link

Request with malformed characters causes Kodi Nexus to crash #14

Closed b-jesch closed 7 months ago

b-jesch commented 1 year ago

While updating the movie library "artwork dump" seems to pickup a wrong datafield and calling the online libraries with malformed characters:

2023-01-21 11:10:21.600 T:13585 debug <CWebserver[8080]>: request received for B>�����HS��י�r�Կ�-0�ylU�� 2023-01-21 11:10:21.600 T:13585 debug <libmicrohttpd>: Received malformed line (no colon). Closing connection. 2023-01-21 11:10:21.600 T:13585 debug <libmicrohttpd>: Error processing request (HTTP response code is 400 (Request malformedYour HTTP request was syntactically incorrect.')). Closing connection. 2023-01-21 11:10:21.600 T:13585 debug : Connection was closed while sending response headers. 2023-01-21 11:10:22.608 T:13587 debug <CWebserver[8080]>: request received for W�t�Յ�bV�z#���/D�B�TQMb��� 2023-01-21 11:10:22.608 T:13587 debug : Received malformed line (no colon). Closing connection. 2023-01-21 11:10:22.609 T:13587 debug : Error processing request (HTTP response code is 400 (<html><head><title>Request malformed</title></head><body>Your HTTP request was syntactically incorrect.</body></html>')). Closing connection. 2023-01-21 11:10:22.609 T:13587 debug <libmicrohttpd>: Connection was closed while sending response headers. 2023-01-21 11:10:22.621 T:12962 debug <general>: Sink changed The only solution now is disable artwork dump.

rmrector commented 1 year ago

Please post full debug log. Turn on debug logging, restart Kodi, then recreate the issue. Upload to a paste site like https://paste.kodi.tv/ , then add the link in a comment here.

b-jesch commented 1 year ago

Here we go, a complete Log until Kodi has crashed: https://paste.kodi.tv/uyexojuvod.kodi

rmrector commented 1 year ago

Thanks.

I'll need to do some more investigation into this, but this may be related to the Artwork Dump feature "Automatically preload local video library artwork to Kodi texture cache" on the Advanced page of the add-on configuration. Disabling that and the matching music library may avoid the crash, at least.

Did you use the same video library with Artwork Dump and Kodi 19 Matrix? Like the same set of TV shows.

b-jesch commented 1 year ago

This is a scan of the video library (movies and TVshows) on Kodi 20 (Nexus) after a fresh Migration from Matrix. The database is a shared MariaDB on a NAS. There are multiple databases present because of a long Kodi history (MyVideo117.db ... MyVideo121.db). Maybe AD picked up the wrong database or a wrong field from MyVideo121.db. Maybe Kodi has changed the data tables or there is a migration bug to external SQL databases. Don't know.

...may be related to the Artwork Dump feature "Automatically preload local video library artwork to Kodi texture cache" on the Advanced page of the add-on configuration.

Will check this out today in the evening.

b-jesch commented 1 year ago

I've disabled the option "Automatically preload local video library artwork to Kodi texture cache", same for music library and the issue has not shown. A complete scan of video library with more then 3500 entries has completed without issues, more than 300 artwork was updated by AD.

rmrector commented 7 months ago

0.3.0 uses a different process to preload artwork, so Kodi may no longer crash with it enabled.

b-jesch commented 7 months ago

Works again without any issues and enabled "Preload local video library artwork". Thank you.