Specify 7 crashes when attempting to add tree record from CO / CE query dialogs

Encountered this error when trying to fix some records in our geography tree. When working with the tree, I was trying to move a node in the “State” rank to be a child of a node in the same rank.

I wanted to make “South Wales” (which is not a real geographic place) a child of “Wales”, or alternatively synonymize it with “Pembrokeshire” (since the only record we have in our database from “South Wales” is from the county of Pembrokeshire.)

The tree wouldn’t allow me to do this (“Can’t move this node here”) I assume because the node has a defined rank and cannot be moved into a rank that differs from the rank it is defined as currently.

If you open the node and attempt to change the rank, the dialogue window query box for Rank does not populate with any existing ranks. And if you attempt to add a rank manually from the menu, it causes a crash.

Specify 7 Crash Report - 2024-07-09T17_38_02.764Z.txt (822.5 KB)

Hi @nfshoobs,

To move a node to a lower rank:

  1. Change the ‘Parent of Geo’ field to the newly desired parent
  2. The appropriate rank will become available in the ‘Geographic Rank’ field
  3. Save your changes

However, you will first need to stop using the auto generated form.

This should be done by unchecking the option in the Form Definition section of the FormMeta dialog:

The auto generated forms use query combo boxes for the ‘Geographic Rank’ and ‘Parent of Geo’ fields. To function properly, the ‘Geographic Rank’ field must be a pick list.

Let me know if you have any further questions!

– Bronwyn

Neither of those options solve the issue. Tree crashes with a cascade of what appears to be that same error message. When “use auto generated form” is unchecked, I am unable to change the parent of geo of any record in the geography tree, and I am also unable to enter a value other than the existing value to the Rank picklist.
I fixed my particular issue just by deleting the node and updating the locality record itself.

Nate –

Ah, I see the source of the problem now.

While the auto generated form poses an issue, changing the rank of a node that already has dependent child nodes is paramount. Child nodes that already exist at the rank you’re trying to move the parent node to will result in the bad tree definition errors you’ve reported.

I have written a feature request (#5089) to improve the handling for this in the UI so the problem is clear to the user when attempting this.

I hope this provides some clarity on the behavior!

– Bronwyn