|  09-29-2013, 03:43 PM | #1 | 
| Evangelist            Posts: 404 Karma: 401800 Join Date: Jun 2011 Device: Pocketbook 902 / Ipad air/ kindle paperwhite | 
				
				Goodreads_rating DEPRECATED
			 
			
			There were several who asked for a plugin which can get and store the decimal rating of goodreads. I gave it a try, just because I like to tackle a problem. But I am not a very good programmer. So this is more or less for fun and there sure will be better/smarter ways to solve this. This thread will be deprecated. The two plugins you need: 1. Goodreads_rating You can find it in this thread or download it within Calibre:Preferences->Plugins-> new_plugins. 2. frating You can find it in this thread or download it within Calibre:Preferences->Plugins-> new_plugins. If you used the zip files from this thread, than delete those plugins and start with the new ones. Last edited by DoctorOhh; 10-22-2023 at 09:17 PM. Reason: Plugin DEPRECATED | 
|   |   | 
|  10-02-2013, 12:57 AM | #2 | 
| She/Her            Posts: 87 Karma: 142774 Join Date: Aug 2009 Location: Perth, Australia Device: Kindle PW5 (G001PX) PW3 PW1 | 
			
			Thanks for this, I'd been hoping someone would create a plug-in like this. The only problem I'm having is that any ebook that doesn't have a publisher listed on Goodreads doesn't get a rating downloaded. Out of the 574 ebooks I've run this against 166 didn't get a rating. I'm guessing that if the publisher field comes back blank the plug-in can't write the "#Pr.Barnart# Rating" to calibre, maybe it might be better to write the "#Pr.Barnart# Rating" to a guaranteed field like Title. | 
|   |   | 
| Advert | |
|  | 
|  10-02-2013, 02:44 PM | #3 | |
| Evangelist            Posts: 404 Karma: 401800 Join Date: Jun 2011 Device: Pocketbook 902 / Ipad air/ kindle paperwhite | Quote: 
 Even is de publisher is blank, the separator and the rating should be added en frating will split them up to blank and rating. But maybe there is a problem with the value of the publisherfield in case it is not filled. There is no need to take another field, because we can force the plugin to fill the publisher field , before adding the extra information. I don't like to use the title or authors field, because they er also used for sorting actions. After checking I wil give you an update, so please give me a title to check. | |
|   |   | 
|  10-02-2013, 07:02 PM | #4 | 
| She/Her            Posts: 87 Karma: 142774 Join Date: Aug 2009 Location: Perth, Australia Device: Kindle PW5 (G001PX) PW3 PW1 | 
			
			Thanks for looking in to this. These two books are both showing the same issue http://www.goodreads.com/book/show/12430013 http://www.goodreads.com/book/show/15987754 | 
|   |   | 
|  10-03-2013, 01:01 PM | #5 | 
| Evangelist            Posts: 404 Karma: 401800 Join Date: Jun 2011 Device: Pocketbook 902 / Ipad air/ kindle paperwhite | 
			
			Ok, thank you for the examples. I made an update for the goodreads-rating plugin 0.1.3. You can download it at the starttopic of this thread. The update checks if the publsher is not known en prevents the value to be Null or None. You can test it. | 
|   |   | 
| Advert | |
|  | 
|  10-03-2013, 10:55 PM | #6 | 
| She/Her            Posts: 87 Karma: 142774 Join Date: Aug 2009 Location: Perth, Australia Device: Kindle PW5 (G001PX) PW3 PW1 | 
			
			Thank you, it's working perfectly! This is so helpful.
		 | 
|   |   | 
|  08-23-2014, 01:19 PM | #7 | 
| Connoisseur  Posts: 60 Karma: 10 Join Date: Oct 2010 Location: Texas Device: Galaxy Tab 3, nook, Nexus 7, iPad | 
			
			Did the most recent upgrade and noticed my frating/goodreads rating plugin is missing....any ideas?
		 | 
|   |   | 
|  08-23-2014, 04:56 PM | #8 | |
| Well trained by Cats            Posts: 31,249 Karma: 61360164 Join Date: Aug 2009 Location: The Central Coast of California Device: Kobo Libra2,Kobo Aura2v1, K4NT(Fixed: New Bat.), Galaxy Tab A | Quote: 
 You have 3 choices: Bribe someone to update the PI code:  Roll back to Calibre 1.48 Wait it out  | |
|   |   | 
|  08-24-2014, 02:52 PM | #9 | |
| Evangelist            Posts: 404 Karma: 401800 Join Date: Jun 2011 Device: Pocketbook 902 / Ipad air/ kindle paperwhite | Quote: 
 It is not an "öffical" - plugin , so it is not mentioned in Calibre. Problems could be related to using calibre 2.0 ( with qt5). But the goodreads_plugin is based on the orignal goodread plugin from Kiwidude. So if that changes,the goodreads_rating should be medofied too. I ported the two plugins (goodreads_rating en frating) for using qt5. I think that will do. Please try. PS: Without bribe   | |
|   |   | 
|  08-25-2014, 05:50 AM | #10 | 
| Evangelist            Posts: 404 Karma: 401800 Join Date: Jun 2011 Device: Pocketbook 902 / Ipad air/ kindle paperwhite | 
			
			The new verslons are available at the start-topic of this thread.
		 | 
|   |   | 
|  08-30-2014, 12:30 PM | #11 | |
| Connoisseur  Posts: 60 Karma: 10 Join Date: Oct 2010 Location: Texas Device: Galaxy Tab 3, nook, Nexus 7, iPad | Quote: 
  And thanks to theducks for suggesting I hang tight..... | |
|   |   | 
|  05-01-2015, 02:48 PM | #12 | 
| Member  Posts: 10 Karma: 10 Join Date: May 2013 Device: Kindle for Android | 
			
			Hello. It doesn't works in Calibre 2.17 (64bits) in Windows 7. I get this: Code: calibre, version 2.17.0
ERROR: Excepción no considerada: <b>TypeError</b>:%d format: a number is required, not NoneType
calibre 2.17 [64bit]  isfrozen: True is64bit: True
Windows-7-6.1.7601-SP1 Windows ('64bit', 'WindowsPE')
('Windows', '7', '6.1.7601')
Python 2.7.9
Windows: ('7', '6.1.7601', 'SP1', 'Multiprocessor Free')
Successfully initialized third party plugins: Count Pages && Goodreads && frating
Traceback (most recent call last):
  File "calibre_plugins.frating.main", line 129, in start_column
  File "calibre_plugins.frating.main", line 140, in check_column
  File "calibre_plugins.frating.main", line 58, in make_gr
TypeError: %d format: a number is required, not NoneTypeand with the second button: Code: calibre, version 2.17.0
ERROR: Excepción no considerada: <b>ConstraintError</b>:ConstraintError: UNIQUE constraint failed: custom_columns.label
calibre 2.17 [64bit]  isfrozen: True is64bit: True
Windows-7-6.1.7601-SP1 Windows ('64bit', 'WindowsPE')
('Windows', '7', '6.1.7601')
Python 2.7.9
Windows: ('7', '6.1.7601', 'SP1', 'Multiprocessor Free')
Successfully initialized third party plugins: Count Pages && Goodreads && frating
Traceback (most recent call last):
  File "calibre_plugins.frating.main", line 121, in start_change
  File "calibre_plugins.frating.main", line 140, in check_column
  File "calibre_plugins.frating.main", line 57, in make_gr
  File "site-packages\calibre\db\legacy.py", line 692, in create_custom_column
  File "site-packages\calibre\db\cache.py", line 57, in call_func_with_lock
  File "site-packages\calibre\db\cache.py", line 1756, in create_custom_column
  File "site-packages\calibre\db\backend.py", line 870, in create_custom_column
  File "site-packages\calibre\db\backend.py", line 793, in execute
  File "c:\cygwin64\home\kovid\sw\build\apsw-3.8.2-r1\src\cursor.c", line 231, in resetcursor
ConstraintError: ConstraintError: UNIQUE constraint failed: custom_columns.label | 
|   |   | 
|  05-01-2015, 07:11 PM | #13 | 
| Evangelist            Posts: 404 Karma: 401800 Join Date: Jun 2011 Device: Pocketbook 902 / Ipad air/ kindle paperwhite | 
			
			Did you restart calibre and tried the second button after that?
		 Last edited by Pr.BarnArt; 05-02-2015 at 03:02 AM. | 
|   |   | 
|  05-02-2015, 10:20 AM | #14 | 
| Evangelist            Posts: 404 Karma: 401800 Join Date: Jun 2011 Device: Pocketbook 902 / Ipad air/ kindle paperwhite | 
			
			I made a fix for the bug that was mentioned by maniattico. ( due to a function named create_custom_columns, which is not returning a num anymore) It is important to restart calibre after creating the column. There is a new version 2.1 available at the start-topic of this thread. The modified goodreads plugin is the same version 1.1.8, so no changes for that file. You can use the existing one (goodreadsX). Last edited by Pr.BarnArt; 05-02-2015 at 10:24 AM. | 
|   |   | 
|  05-04-2015, 02:52 PM | #15 | |
| Member  Posts: 10 Karma: 10 Join Date: May 2013 Device: Kindle for Android | Quote: 
 I install both files, restart calibre. Check and create custom column, restar calibre. I do a metadata search with Goodreads_Rating, and it bring me all the metadata, included the rating in stars (in the log I can see: "Rating : 1.9"). I clic in Set decimal reting, and I get: Code: calibre, version 2.17.0 Updated database: Finished extracting rating from publisherfield - for a total of 0 books  Thanks!! | |
|   |   |