View Single Post
Old 06-27-2019, 02:42 PM   #4
Ubiquity
Member
Ubiquity began at the beginning.
 
Posts: 17
Karma: 10
Join Date: Apr 2019
Device: Android phone
I wouldnot say that my artist string is in list form. Fetching it and joining to reult string which initializes Metadata structure

Code:
authors = root.xpath('//h2[@class="authornames"]/span/a/text()')
if authors:
  authors = ' & '.join(authors).strip()
.
.
.
mi = Metadata(title, authors)
My issue seem to relate with unknown codepage in which Calibre operates the plugin.

If I parse the detail page in testing standalone script, all acuted string literals print out in proper form. If I print same string constants from plugin source, they print out in broken form, representing higher ascii characters in two byte unreadable chunks. But both plugin sources and testing script are saved in UTF-8 encoding.
Ubiquity is offline   Reply With Quote