View Single Post
Old 09-04-2019, 05:46 PM   #7
BetterRed
null operator (he/him)
BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.
 
Posts: 21,736
Karma: 29711016
Join Date: Mar 2012
Location: Sydney Australia
Device: none
Quote:
Originally Posted by jcrawfordx View Post
. . . Perhaps this phantom "Formats" problem is actually a bug that should be looked into someday???
If the template in the 'phantom "Formats"' column is {:'approximate_formats()'}, there is no bug. See ==>> approximate_formats()

Quote:
returns a comma-separated list of formats that at one point were associated with the book. There is no guarantee that this list is correct, although it probably is.
In my Test library I have a column called #approx_formats/Approx Formats, which uses that template. It shows a single string e.g. "DOCX,EPUB,AZW3" in the book details panel, if I click on it calibre does a search e.g #formats:"=DOCX,EPUB,AZW3" and shows me all the books that have that string in #approx_formats.

Maybe your crash is due to the fact that you have two columns with similar names, the built column formats/Formats and the user defined custom column #formats/Formats. I used a different name for my custom column because having them the same would have confused me .

You might want have a look at the formats_paths() function. However, I am pretty sure this interrogates the file system, which will have a negative impact on performance -- hence the provision of the approximate_formats function.

Added: I am using Win 10 Pro 1809 and calibre 3.47.1.

BR

Last edited by BetterRed; 09-04-2019 at 05:55 PM.
BetterRed is offline   Reply With Quote