Release cdART Manager Script "NG" - Printable Version +- Kodi Community Forum (https://forum.kodi.tv) +-- Forum: Support (https://forum.kodi.tv/forumdisplay.php?fid=33) +--- Forum: Add-on Support (https://forum.kodi.tv/forumdisplay.php?fid=27) +---- Forum: Program Add-ons (https://forum.kodi.tv/forumdisplay.php?fid=151) +---- Thread: Release cdART Manager Script "NG" (/showthread.php?tid=256958) |
RE: cdART Manager Script "NG" - Reelyator - 2020-12-27 After testing several configurations: Rapier with Kodi 18.9 on a Android Mediaplayer (Zidoo x20) Rapier with Kodi 18.8 on a Win8 PC Rapier with Kodi 18.2 on a Win10 PC i got the impression that i am getting most reliable results with cdart.png. discart.jpg or discart.png do not always work..... RE: cdART Manager Script "NG" - Gade - 2020-12-27 discart.png is only for Rapier in Kodi 19. cdart.png images will work for all v18 and v19 versions of Kodi. I might remove that for v20 though. RE: cdART Manager Script "NG" - rpharrison - 2022-05-30 Hi, I came across this addon by chance as an optional dependency for the skin I'm using (Eminence 2 -mod). Decided to have a go at installing it, got a bunch of errors about python. I have spent a little time converting it to python 3, enough so that it loads in 19.4. No testing of functionality has been done yet. If anyone else is still interested in using this addon with Matrix, you can see my changes at: https://github.com/rpharrison/script.cdartmanager Will report back after some testing. RE: cdART Manager Script "NG" - rpharrison - 2022-05-30 With music in the library CDAM doesn't appear to be picking it up, haven't investigated further. RE: cdART Manager Script "NG" - Karellen - 2022-05-30 @rpharrison I think this addon is deprecated. It has not been updated in a long time, and certainly has not been updated for the artwork changes that occurred in v18 and v19. IIRC it uses incorrect artwork names (cdart instead of discart etc), and makes no use of the Artist Information Folder... https://kodi.wiki/view/Artist_information_folder Artwork Dump is probably the best replacement for this addon for v19... https://forum.kodi.tv/showthread.php?tid=360078 RE: cdART Manager Script "NG" - rpharrison - 2022-05-31 Decided to continue out of personal interest, it is kind of working: 2022-05-31 01:28:07.406 T:16008 DEBUG <general>: [cdART Manager] - b'Retrieving MusicBrainz Info - Checking by Artist - Not including Singles or Live albums' 2022-05-31 01:28:07.406 T:16008 DEBUG <general>: [cdART Manager] - b'Retrieving HTML Source' 2022-05-31 01:28:07.406 T:16008 DEBUG <general>: [cdART Manager] - b'Fetching URL: http://musicbrainz.org/ws/2/release-group/?query="Greatest+Hits"~2 AND artist:"Red+Hot+Chili+Peppers" NOT typeingle NOT type:live&limit=1' 2022-05-31 01:28:07.406 T:16008 ERROR <general>: EXCEPTION Thrown (PythonToCppException) : -->Python callback/script returned the following error<-- - NOTE: IGNORING THIS CAN LEAD TO MEMORY LEAKS! Error Type: <class 'AttributeError'> Error Contents: module 'urllib' has no attribute 'FancyURLopener' Traceback (most recent call last): File "C:\Users\info\AppData\Roaming\Kodi\addons\script.cdartmanager\lib\gui.py", line 896, in onClick cdam_db.update_database(False) File "C:\Users\info\AppData\Roaming\Kodi\addons\script.cdartmanager\lib\cdam_db.py", line 1145, in update_database updated_albums, canceled = update_missing_album_mbid(combined, background=background) File "C:\Users\info\AppData\Roaming\Kodi\addons\script.cdartmanager\lib\cdam_db.py", line 1044, in update_missing_album_mbid musicbrainz_albuminfo, _ = get_musicbrainz_album(cu.get_str(album["title"]), File "C:\Users\info\AppData\Roaming\Kodi\addons\script.cdartmanager\lib\mb_utils.py", line 150, in get_musicbrainz_album htmlsource = cu.get_html_source(url, "", save_file=False, overwrite=False) File "C:\Users\info\AppData\Roaming\Kodi\addons\script.cdartmanager\lib\cdam_utils.py", line 152, in get_html_source class AppURLopener(urllib.FancyURLopener): AttributeError: module 'urllib' has no attribute 'FancyURLopener' -->End of Python script error report<-- RE: cdART Manager Script "NG" - stef.an - 2022-05-31 Long time no see! E-Mail notifications still work on very old posts and rarely used accounts As Karellen said this script is deprecated for a while. Basically because hardly anyone used it since 18+. Afaik "normal" artwork is retrieved through scrapers by now and the fancy things like rotating discs aren't displayed by most of the skins out there. But hey, if you do this just of pure interest then don't mind asking if you have any questions. I'm not the creator but a few years ago I've touched almost every line of code. RE: cdART Manager Script "NG" - rpharrison - 2022-06-01 Hi stef.an, Good to see you are active! I did get a little beyond the error of my previous post, but still trying to get it to create the database. 2022-05-31 23:42:37.170 T:26504 ERROR <general>: File "C:\Users\info\AppData\Roaming\Kodi\addons\script.cdartmanager\lib\cdam_utils.py", line 177, in get_html_source sock = urllib.request.urlopen(url) 2022-05-31 23:42:37.170 T:26504 ERROR <general>: http.client.InvalidURL: URL can't contain control characters. '/ws/2/release-group/?query="The+Poison"~2 AND artist:"Bullet+for+My+Valentine"&limit=1' (found at least ' ') 2022-05-31 23:42:37.170 T:26504 ERROR <general>: 2022-05-31 23:42:37.170 T:26504 DEBUG <general>: [cdART Manager] - b'!!Unable to open page http://musicbrainz.org/ws/2/release-group/?query="The+Poison"~2 AND artist:"Bullet+for+My+Valentine"&limit=1' Seems to me like the url is being malformed and I've yet to figure a way to correct this... This is pretty much my first exposure to python besides editing a few scripts on webservers, sadly I'm not familiar enough with python (though I'll probably persevere for a while yet)! RE: cdART Manager Script "NG" - stef.an - 2022-06-05 Consider me "semi-active" so it might take a while until I answer... Also I'm a Java programmer so my a python skills are very, very limited But here it looks like python 3 doesn't like unencoded parameters anymore. For this special case the easy fix would be replacing the whitescpace in the url with + or %20 - so replacing by and the same with all other URLs in mb_utils.py shoud fix this one. RE: cdART Manager Script "NG" - rpharrison - 2022-06-05 Thanks for taking the time to reply stef.an, and for looking into this code again! Your hints did get me a bit further, CDAM now at least attempts to create the database on first run. When trying to update it throws a TypeError: Quote:2022-06-05 21:05:06.532 T:27040 ERROR <general>: Traceback (most recent call last):I tried to research how to fix this but can't figure out the correct way to make the search pattern be i.e. just bytes: like match = re.search(b'''<release-group-list count="(?:.*?)">(.*?)</release-group-list>''', htmlsource). I feel this is roughly along the right lines, but I'm implementing it wrongly. Anyway thanks for your help! RE: cdART Manager Script "NG" - stef.an - 2022-06-06 So sock.read() returns an array of bytes now, not the plain string as before. You'll have to decode it in order to use it as a string: https://docs.python.org/3/library/stdtypes.html#bytes.decode tldr; use htmlsource = sock.read().decode("utf-8") instead of htmlsource = sock.read() in cdam_utils.py RE: cdART Manager Script "NG" - stef.an - 2022-06-06 (2022-06-05, 22:14)rpharrison Wrote: I tried to research how to fix this but can't figure out the correct way to make the search pattern be i.e. just bytes: like match = re.search(b'''<release-group-list count="(?:.*?)">(.*?)</release-group-list>''', htmlsource). I feel this is roughly along the right lines, but I'm implementing it wrongly.You got this one vice versa, convert the htmlsource to string insead of the regex to bytes |