Ghini / ghini.desktop

plant collections manager (desktop version)
http://ghini.github.io/
GNU General Public License v2.0
24 stars 14 forks source link

improved workflow for renaming and synonyms #444

Open RoDuth opened 6 years ago

RoDuth commented 6 years ago

Expected behaviour

You should be able to change the name of a taxon and record the current name as a synonym without leaving the editor or losing any of the attached data (accessions, pictures, notes, etc.)

Actual behaviour

example: We had to change Paraserianthus toona to Falcataria toona. The only way I can see is to do this and keeping the original name as a synonym is this convoluted process:

  1. search gen='Paraserianthus', open it and rename it Falcataria
  2. recreate Paraserianthus genus
  3. reopen Falcataria and add Paraserianthus as a synonym
  4. create a new species entry for Paraserianthus toona close/save
  5. reopen Falcataria toona and add Paraserianthus toona as a synonym in the "Additional info" tab.

Opinions and suggestions

This is just an example of a possible solution: When you edit any of the taxonomic fields for a family, genus, species and click ok you have a pop up that gives you the option to "create copy of original as a synonym" or "edit original only". (Similar to the way that you currently get a "Are you sure you want to lose your changes?" if you click cancel.) If you select "create copy of original as a synonym" a new entry is created with the old name and it is added as a synonym for the new taxon just saved.

In the above example you could even go further and at step 1 above ask "create copy of original as a synonym" then if this is selected ask a second question: "create synonyms for all members" of the taxon (i.e. ghini could "create copy of original as a synonym" for all species of the genus Falcataria). (The species level synonyms are needed for many reasons including to show up in results if you have search_return_synonyms set to true.) This would change the above 5 step process to 1 step for a simple genus name change.

RoDuth commented 6 years ago

A more simple example would be changing the species name when a species is renamed. A couple of years ago we had a species collected by the team formally named so Actephila sp. Koumala (I.G Champion 870) became Actephila championiae

using that example the workflow went like this:

  1. search for gen='Actephila' expand the genus then open Actephila sp. Koumala (I.G Champion 870), copy the species name to avoid misspellings and change it to championiae close/save
  2. right click Actephila, add species and create a new sp. Koumala (I.G Champion 870) close/save
  3. open Actephila championiae and add Actephila sp. Koumala (I.G Champion 870) as a synonym

This could be one step.

mfrasca commented 6 years ago

let me understand your Paraserianthus / Falcataria example better.

it doesn't sound an easy thing to do, and I would like to get it as straight as possible.

your other example is according to me quite a different case, and asks for a different solution, I'm going to split it otherwise we're back to talking of two issues in the same conversation.

RoDuth commented 6 years ago

I don't think they are separate issues. for my Paraserianthus / Falcataria example, If all you had is the "create copy of original as a synonym" option at genus and species level you'd make it a lot easier. It was only one entry for my Paraserianthus / Falcataria example but there have been others with more species.

so my "create copy of original as a synonym" feature would just

  1. grab a copy of the taxonomic data (genus, species, infraspecific parts, author, hybrid flag, cultivar group, species qualifier) from the database prior to the edit (shouldn't be hard if the edits haven't been saved yet),
  2. save the edits to the database
  3. create a new species entry from the copied taxonomic data
  4. add the new copied taxon as a synonym to the edited taxon.
RoDuth commented 6 years ago

I'll add that at genus level the taxonomic data would be (family, epithet, author)

The "create copy of original as a synonym" feature would only appear when changes had been made to these fields.

mfrasca commented 6 years ago

FYI: in ghini-1.0, starting I can't remember which patch, you can refer to the all epithet fields (genus field of the Genus class, sp field of the Species class, family field of the Family class) all as epithet. in ghini-3.1 I have the opposite, you can still use those now deprecated field synonyms. please don't use them when trying to explain things, they are really confusing according to me. the fields named family and genus in particular: depending what object mentions them, they have different type.

this as explanation to the edit to your comment

The "create copy of original as a synonym" feature would only appear when changes had been made to these fields.

I think I now understand why you consider this shuffling in the database (this issue, and issue #445) as the same thing. please check what I suggest at https://github.com/Ghini/ghini.desktop/issues/445#issuecomment-429305397

RoDuth commented 6 years ago

re: https://github.com/Ghini/ghini.desktop/issues/445#issuecomment-429305397

essentially. except

  • for any given species X in a 1.0/3.1 database, I want to be able to
  • add a new accepted name (a new Species object Y),
  • open the Species Editor on Y, and —on confirming the edit—
  • change all accessions previously associated to X so that they become accessions of Y, and
  • copy all notes (and pictures, what else?) from X to Y, and
  • make sure that X is now a synonym for Y.

is the long way around. you don't need to copy all notes, "change all accessions...", etc. if you just rename the species x and recreate a species with the original name and use that as a synonym. i.e.

so my "create copy of original as a synonym" feature would just

  1. grab a copy of the taxonomic data (genus, species, infraspecific parts, author, hybrid flag, cultivar group, species qualifier) from the database prior to the edit (shouldn't be hard if the edits haven't been saved yet),
  2. save the edits to the database
  3. create a new species entry from the copied taxonomic data
mfrasca commented 6 years ago

I don't mind describing "the long way", if that is a better representation of the logic behind your wish. including technical considerations in the functional description makes the functional description less clear. it is helpful if a description goes linearly, not leave points in the air (as you do in point 1) to later complete a few steps later (what you do in point 3). also please do not include considerations that are no part of the description (shouldn't be so hard). ;-)

so please don't ask me to decipher a new description if you're stating the same I'm saying, but in your own words, and suggesting a technical implementation. I mean: if you reach a technical description, you can also go all the way and implement it.

mfrasca commented 5 years ago

@RoDuth , check #456, and the different point of view taken there. not helping you do what you describe as a solution to the problem, but address the original problem differently: so that you alter what you see, without altering so much in the database. and very easy to reverse if needed.

I will describe this for an autonym …

this all is achievable with flags and synonymies, no need for all the handling we described here.