evolverine / covid-19-anki-deck

An Anki deck for COVID-19 information for the general public
GNU General Public License v3.0
5 stars 2 forks source link

Test how a change in the note model is reflected in updates #6

Open evolverine opened 4 years ago

evolverine commented 4 years ago

e.g. number of fields

aleksejrs commented 4 years ago

I add fields for MorphMan, and the next update asks me to choose the target note type. That "Front…" note type is the original note type, not the modified one, whose added fields are lost every time.

evolverine commented 4 years ago

Do you mean that you get this dialogue every time you update? (I am currently not a user of MorphMan.)

aleksejrs commented 4 years ago

Yes, and the target type doesn't have the fields I added. My modified one is updated, and cards are moved into Active::COVID-19_2 (if they are in Active::COVID-19; I haven't tried updating with them being anywhere else).

aleksejrs commented 4 years ago

MorphMan requires a field called "MorphMan_FocusMorph" by default.

image

evolverine commented 4 years ago

What is the target type? Can you post a screenshot?

aleksejrs commented 4 years ago

image

evolverine commented 4 years ago

Thank you. Indeed, it looks like MorphMan is adding that extra field and you need to re-convert the note types all the time. I'm afraid that I can't think of what I could help with. I imagine any other collaborative deck you'd subscribe to would make you go through this procedure on each update due to MorphMan as well. Perhaps it's worth writing to them about this issue? (In any case, keep in mind that other users sometimes have to go through this kind of dialogue too, but only when this deck updates the number of fields, or the CSS, things like that. Whenever that happens I increment the major version — and given we're at v2.2.0, it already happened twice.) Best of luck.

aleksejrs commented 4 years ago

I add the extra fields manually: MorphMan only fills them in.

It's you who is using CrowdAnki itself, so you should be able to understand it (its issue tracker, in particular) better than I do. Maybe this: https://github.com/Stvad/CrowdAnki/issues/33

evolverine commented 4 years ago

I might understand CrowdAnki better (not sure though), but I do not understand your problem and your goals better than you. I recommend you open a ticket in the CrowdAnki project, the maintainer tends to be responsive and kind, and I'm sure you'll get to a place of more clarity, and maybe even help make some useful changes in CrowdAnki. Good luck.

ohare93 commented 4 years ago

I am a user of both Morphman and CrowdAnki, currently in the process of implementing a PR for CrowdAnki which could help with this @aleksejrs. I hope to have it be possible for deck moderators to just include an optional field like "MorphMan_FocusMorph", which can then be used or not by CrowdAnki, as a config setting.

However I do not fully understand what the issue is, from your description. Since this deck does not currently contain the field "MorphMan_FocusMorph" CrowdAnki will (quite rightly) be confused about which note model you want to sync it into (as your cards do have that field) and will ask for confirmation. At that stage you should be able to simply select the appropriate fields to merge into, not select any which go to MorphMan_FocusMorph, and then simply run a Morphman db regen with Ctrl+M to have that field be repopulated again. So overall you will get the same result, but with an annoying manual step and recalculation in the middle. That annoying step I hope to resolve in the next month or so, but is that your issue?

aleksejrs commented 4 years ago

@ohare93, there is only one relevant target note type available, and it does not have MorphMan_FocusMorph, so I have to add the field again (and wouldn't it be nice to have the optional fields as well?). Also, I have many MorphMan-processable cards, including incremental reading ones, so recalculation takes a few minutes.

ohare93 commented 4 years ago

there is only one relevant target note type available

"Relevant note type"? I believe you should be able to select any note type :thinking: You said that you have been adding in the MorphMan_FocusMorph field, and your NoteTypes should be shown, hmm. Can you be explicit in what actions you take in order to get into this state so I may try and replicate?

For example, if I go and download a CrowdAnki file for the latest release of Ultimate Geography and import that into CrowdAnki via File -> CrowdAnki: Import From Disk, selecting the unzipped folder. Then I get the following popup:

image

Clicking on the "New Note Type" dropdown gives me a selection of every single note type I have, which I can change the Field mappings to suit as I like, below.

image

Do you get to this menu and are only provided with one note type? Or do you go through a different means of importing the deck? :thinking: (Like the Github importer)

aleksejrs commented 4 years ago

I mean there is no other note type called anything like Front <--> Back Source Context. I added the fields to the note type without renaming it or adding a new one. Maybe that's why? I'll try cloning the note type and modifying that, but I am not sure how's that for a solution.

Update: choosing the modified note type hangs Anki.