Cards not updating with Ankihub changes

Hello,

Iā€™m using the Anking for steps 1/2/etc deck. I seem to be having trouble syncing with ankihub, and Iā€™ll give an example. For note nid:1518400488208, the following text is supposed to appear in the extra field
image

That text does not appear in my extra field because I deleted the contents of the extra field when I realized the possibility that my notes arenā€™t being updated (note that the issue Iā€™m having happens regardless of what changes I make to a non-protected field - if I just add/delete a single character, this problem of non-updating still happens).


(Please ignore the text field, which I edited)

I have the extra field unprotected in the relevant deck,


so that field should update whenever I sync with ankihub
image
image

When I go through these steps, the extra field in the relevant note remains empty.

In case it helps, I am using the most updated version of the Ankihub addon, and I am running Anki Version āØ24.04.1 (ccd9ca1a)ā©
Python 3.9.18 Qt 6.6.2 PyQt 6.6.1

I am logged in to the ankihub addon
image

Please advise.

Thank you so much! Iā€™m now quite worried that a number of my cards arenā€™t being updated.

I am slighly aware of the ā€œreset local changesā€ option, but I thought the whole point of ankihub is that when syncing with ankihub, ankihub will check if the unprotected fields in my notes differ from whatā€™s in the ankihub database, and if there is a difference, my local notes will be updated to reflect exactly what is in the ankihub database.

Hello,

A few things:

Ankihub does not automatically update every field of every card with every sync. So, for example, if you were to edit the extra field for a given card that does not mean that the changes you make would be overwritten each and every time you sync. Updates are only sent out, and written, from Ankihub typically (or at least primarily) when there are changes on the Ankihub side.

Thus, in your case, editing a field and then syncing wonā€™t illustrate much unfortunately. Unless that field has recently been edited on the Ankihub side, there will be no new changes to write out and therefore your local edits will likely persist until there is an Ankihub update that gets sent out.

This probably illustrates well the distinction: Ankihub isnā€™t checking for every conceivable discrepancy upon every single sync. When there are updates on the Ankihub side they will be sent out and, thereupon, if there is a discrepancy they will be made to agree. But itā€™s not scanning every single field every single sync, if that makes sense.

Is there anything else that has led you to think that your cards are not updating?

Probably a better way to verify that you are, in fact, receiving updates would be to check here from the browser:

image

You can check updated today, modified after sync, updated since last review, etc. All will give you information about cards in your collection that have been recently modified in some way or another, which can verify that you are, in fact, receiving updates.

So long as you have an active membership, and are logged into the Ankihub addon from within Anki, you should be receiving updates as they occur. If for whatever reason you find that this is not the case please feel free to let me know and we can troubleshoot further

Please let me know if that answers your question, and if thereā€™s anything else I can help with. :slight_smile:

1 Like

@frederickdouglass

I believe if you protect the text field, AnkiHub will have a bit more trouble updating things automatically so resetting local changes will be more beneficial for your case if you want to get all changes

Thank you both for your replies.

To help me make sure that Iā€™m understanding everything correctly, please let me know if this seems right:
Ankihub never updates my protected fields/tags. For my unprotected fields, if a field has been changed in ankihub since the last time I synced with ankihub, then the next time I sync with ankihub, that field will be changed to reflect what is in ankihub. This will not happen in either of the following situations: (i) the field is protected and/or (ii) the field has not been updated in ankihub since the last time I synced with ankihub. A field will be updated to reflect what is in ankihub iff both of the following conditions have been met: (i) that field has been altered in ankihub since I last synced with ankihub and (ii) that field is unprotected.

Regarding resetting local changes:
This forces all of my unprotected fields to reflect what is in ankihub, regardless of when that field was last updated in ankihub. Itā€™s an immediate and forced ā€œsyncā€ that will change all my unprotected fields to reflect what is in ankihub, regardless of when the field has last been altered in ankihub.

Regarding the first point:

Correct; anything that is protected, whether field or tag, will not (and cannot) be overwritten by Ankihub. It will be entirely preserved however you decide to edit it locally.

For unprotected fields, they may be overwritten when that field is updated on the Ankihub side. There may be other things on the server side that might trigger the card to be written to, so I canā€™t guarantee that it will only ever happen when that specific field has an update; there may be other conditions specified in the coding that might also trigger a write. But, in general, updates are written out to cards when changes have taken place on Ankihubā€™s server side. This holds as a general rule.

Regarding the second point:

Correct. Resetting local changes ensures that anything that is not protected will be aligned with the existing copy on Ankihubā€™s side. In the vast majority of cases this is a feature that you will never need to use, but it is there in a pinch.

Wonderful, that is incredibly helpful and really helps me understand how the syncing process works on ankihubā€™s end, which is very useful for me to know. I really appreciate your help.

Thanks again!

2 Likes

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.