Of course whether I want to add support to this plugin is another issue . Talk me into it - how would you ideally want to see it working, given how you know the plugin works today?

Personally I would like to be able to set a default in the configuration that would allow the user to select to have books automatically set as owned or not, that way every time I add books to my shelves they would automatically be added as owned. Or if that is not possible, an option on the add feature that let's the user select whether the book is owned or not.

Personally I would not need a feature to have the plugin remove books from being owned, but not sure if others would want such a feature.

Hey KiwiDude. Loving your GR plugin here, but I found a strange bug and I was wondering if you could help me figure out what's the matter?

I am syncing from my Read shelf on Goodroads, to my custom created Read column in Calibre. The Read column is a Y/N kinda thing, and works splendidly. I've linked and synchronized a few hundred books with no problems today. However, when I try to link and sync the last batch of books (perhaps the last 40-50 or so) I get an error:

Code:

calibre, version 0.8.39
ERROR: Unhandled exception: <b>TypeError</b>:list indices must be integers, not unicode
Traceback (most recent call last):
File "calibre_plugins.goodreads_sync.action", line 300, in sync_shelves
File "calibre_plugins.goodreads_sync.action", line 349, in _update_calibre_database_ids_after_sync
File "site-packages\calibre\library\database2.py", line 3097, in set_isbn
File "site-packages\calibre\library\database2.py", line 3049, in set_identifier
File "site-packages\calibre\library\database2.py", line 3025, in get_identifiers
TypeError: list indices must be integers, not unicode

Do you have any clue as to what might be going on, and how I might go about fixing it?

Now that looks an interesting one, it looks like the Calibre database code is not liking the value of the ISBN that is being passed through. I have two suggestions:

(1) See if you can isolate it down to a specific book that is causing the issue. If you can do that, and give me all the info you can on it (existing ISBN/goodreads id it has if any, any info you see on screen when you click the Sync button etc) I can try to replicate it.

(2) Alternatively, what I would hope would work (but not help figure out the cause) is to go to the Customise plugin dialog and change your setting for "When linking to goodreads" to "Never modify the Calibre ISBN".

The thing is, today has been all about matching Goodreads with Calibre, so I've been doing some extensive cleaning on both ends, deleting (and creating ) duplicates back and forth.

My theory is that the books that were causing these problems were books where there was one copy on Goodreads and two copies in Calibre, and then upon syncing I linked first to book A and then on the next sync I linked to book B.

As I was also deleting books between syncing actions (in both places) these duplicates slowly disappeared... which would explain why I can get the error again and again when I run the same books again and again, but if I run a few at a time (getting bored and doing some cleaning on Goodreads in the meanwhile) I can run through all the ones that gave me problems before in smaller batches without getting errors.

Add a Switch edition dialog for a linked book to allow picking another edition for page count/cover purposes

Also allow access to the switch edition dialog from the linked book screen.

There are a couple of circumstances where you will find yourself switching goodreads editions, such as wanting one that has a page count or with a cover. This new feature offers another way of doing this that should be easier than the manual steps otherwise required.

If a book is already linked to goodreads, then you can just use the new Switch edition menu item. If the book is not linked at all, you can use the standard Link to Goodreads dialog, pick the search result you like and then click on the new Switch Edition button to narrow it down.

Very cool, thank you. I was thinking about that lack of feature yesterday, because I sometimes clicked the wrong book and found no way to choose a different one, so I had to cancel out of the entire syncing process and start anew

@ArniVidar - shouldn't need to cancel out of the sync process, because you can always "re-link" a book, regardless of whether it is already linked or not from that screen. Anyways, hopefully you find a workflow you are happy with now.

It can still get a little clumsy when you already have a book added to your Goodreads shelves and then want to switch editions, but I don't have a solution for that (other than get the edition you want right before you start syncing it anywhere else!).

So I see this feature as probably most useful to someone using the latest (beta) of the Count Pages plugin, where you don't have the book on any Goodreads shelves (may not even use Goodreads shelves for that matter) but do want the ability to switch to an edition which has a page count. Or equally for someone who has not yet added a book to their shelves and wants to refine the match.

@ArniVidar - shouldn't need to cancel out of the sync process, because you can always "re-link" a book, regardless of whether it is already linked or not from that screen.

Well, my memory sucks and my attention span wavers, so I knew that if I didn't fix it immediately I would forget it immediately. Thus, it was better to have to re-link 50 books to get that one right, than it would have been to forget it and leave it incorrect

Quote:

Originally Posted by kiwidude

Anyways, hopefully you find a workflow you are happy with now.

Thanks. I spent some quality time with your Goodreads and Duplicates plugins yesterday, and I think near the end of that 12 hour marathon I managed to figure out a workflow that works

Tried the changing of editions and works great. I like that you can see editions and page numbers.

Hope maybe it can be put into simple linking too (to see which edition is chosen), but I usually download goodreads ID with metadata so I rarely need to link manually. And now it's easy to change editions.

The only problem could be in changing edition while in goodreads it remains the old edition. So you need to change both. Maybe there is a way to check which edition is on the shelves? I often add books on goodreads manually (like my to buy list or the books added before I started using calibre or the books I see my friends reading etc) so edition in calibre and goodreads are often different. Downloading/syncing often shows which since you get no results for those books. Unless you end up with duplicates on goodreads. Which can be removed in batch edit in case somebody doesn't know. And again you need to see which edition is in calibre/ which to keep.

Haha - yes there does get a bit of an incentive to organise a workflow as the hours tick by...

Was it you had made a donation today btw? If so, thanks for that as it is very timely. I made the mistake of rolling over when I woke up this morning and stuck my elbow into my Kindle screen (where it was lying from falling asleep reading last night). Needless to say the resounding crack that occurred and the dismay of it being completely knackered work me up completely fairly quickly after that.

@Noughty - the "problem" you refer to is exactly the scenario I described in my previous post as still being "clumsy". I don't have a more elegant solution, and AFAIK there is no API call for "switch edition".

Sorry for your kindle and I don't think it's clumsy . It does the job. Even when downloading metadata/linking books you can end up with wrong edition, but it's not hard to check. And if you add a dupe in goodreads it's also easy to check with batch edit. So it's not really a problem if there is a solution.

Already tried changing metadata because of the page count. Works great.