From: Benny M. <ben...@gm...> - 2009-02-11 17:36:39
|
Ok, the good news appears to be the check and repair tool fixes everything. Can you open a bug ticket: stress test Bad GEDCOMs, add the tar there as well as your remarks you mention here. The FAMC.get should be looked into. Benny 2009/2/11 Jérôme <rom...@ya...> > Hi, > > Here some broken GEDCOMs ... > > ===FAMS.ged=== > > 1. set "Perkins, Alice Paula (I02)" as active person > 2. On RelationView, get a warning > (fixed by "check and repair" tool) > > ===FAMC.ged=== > > 1. set "Smith, Martin (I03)" as active person > 2. open Person Editor > 3. Go on item/tab "References" : 4 parents !!! > (fixed by "check and repair" tool) but when I deleted this database I got : > > Traceback (most recent call last): > File "src/DisplayModels/_PeopleModel.py", line 467, in on_iter_children > return self.mapper.first_child(node) > File "src/DisplayModels/_PeopleModel.py", line 157, in first_child > return self.top_path2iter[0] > IndexError: list index out of range > > ===FAM.ged=== > > 1. On Family View, there is a Family with "None" ID > (fixed by "check and repair" tool) > > ===FAM_CHILD.ged=== > > 1. broken child references on family F0000 > 2. On Family View, get a warning > (fixed by "check and repair" tool) > > > ===FAM_HUSB.ged (take care ...)=== > > 1. On Family View, click on family F0000 > > 30080: ERROR: gramps.py: line 160: Unhandled exception > Traceback (most recent call last): > File "src/PageView.py", line 1023, in _button_press > self.edit(obj) > File "src/DataViews/FamilyList.py", line 215, in edit > EditFamily(self.dbstate, self.uistate, [], family) > File "src/Editors/_EditFamily.py", line 415, in __init__ > dbstate.db.get_family_from_gramps_id) > File "src/Editors/_EditPrimary.py", line 63, in __init__ > self._local_init() > File "src/Editors/_EditFamily.py", line 456, in _local_init > self.load_data() > File "src/Editors/_EditFamily.py", line 618, in load_data > self.update_father(fhandle) > File "src/Editors/_EditFamily.py", line 675, in update_father > self.fbutton_del, self.fbutton_edit) > File "src/Editors/_EditFamily.py", line 849, in load_parent > name = "%s [%s]" % (name_displayer.display(person), > File "src/BasicUtils/_NameDisplay.py", line 540, in display > name = person.get_primary_name() > AttributeError: 'NoneType' object has no attribute 'get_primary_name' > > (fixed by "check and repair" tool) > > > Other messages, maybe not related to one file, but to session ... > > 129590: ERROR: gramps.py: line 160: Unhandled exception > Traceback (most recent call last): > ly_delete_db) > File "src/QuestionDialog.py", line 105, in __init__ > task() > File "src/DbManager.py", line 782, in __really_delete_db > self.dbstate.no_database() > File "src/DbState.py", line 113, in no_database > self.db.close() > File "src/gen/db/dbdir.py", line 1226, in close > raise Errors.DbError(msg) > DbError: Argument invalide -- Open database handle: > /home/jerome/.gramps/grampsdb/4992ea73/source_id.db/source_id > > 129590: ERROR: gramps.py: line 160: Unhandled exception > Traceback (most recent call last): > File "src/ViewManager.py", line 622, in quit > self.state.db.close() > File "src/gen/db/dbdir.py", line 1222, in close > self.__close() > File "src/gen/db/dbdir.py", line 1234, in __close > self.env.txn_checkpoint() > DBError: (0, 'DBEnv object has been closed') > > 179056: ERROR: gramps.py: line 160: Unhandled exception > Traceback (most recent call last): > File "src/DbManager.py", line 758, in __remove_db > self.__really_delete_db) > File "src/QuestionDialog.py", line 105, in __init__ > task() > File "src/DbManager.py", line 782, in __really_delete_db > self.dbstate.no_database() > File "src/DbState.py", line 113, in no_database > self.db.close() > File "src/gen/db/dbdir.py", line 1226, in close > raise Errors.DbError(msg) > DbError: Argument invalide -- Open database handle: > /home/jerome/.gramps/grampsdb/4992f18c/source_id.db/source_id > > > > I only see "warnings" by using FAMS.ged and FAM_CHILD.ged data. > Should Gramps add more warnings ? > > > Jérôme > > > Benny Malengier a écrit : > >> I think you are onto something Jerome. >> >> Looking in GedcomParse, method __person_fams, I see a family handled is >> created and added in the family list of the person (add_family_handle), but >> the family object is not created, and if it does not exist yet, no error is >> raised. >> >> Please try it out with a FAMS line which is no valid family, and see if >> check and repair does not fix it. >> If it does not fix it, the following rule must be added: >> --> go over the family handles of the person, check that family exists, if >> not, delete this handle from the list >> >> Benny >> >> 2009/2/11 Jérôme <rom...@ya... <mailto:rom...@ya...>> >> >> Hi, >> >> Is it possible that importing a GEDCOM may corrupt database by >> importing a person with family-reference but no family object ? >> This could create a family object without IDs or wrong references, >> messages like : >> >> 124101: ERROR: gramps.py: line 160: Unhandled exception >> >> Traceback (most recent call last): >> File "src/DisplayModels/_PeopleModel.py", line 467, in >> on_iter_children >> return self.mapper.first_child(node) >> File "src/DisplayModels/_PeopleModel.py", line 157, in first_child >> return self.top_path2iter[0] >> IndexError: list index out of range >> >> 379262: ERROR: _Tool.py: line 252: Failed to start tool. >> >> Traceback (most recent call last): >> File "src/PluginUtils/_Tool.py", line 248, in gui_tool >> tool_class(dbstate, uistate, options_class, name, callback) >> File "src/plugins/tool/ReorderIds.py", line 90, in __init__ >> db.family_prefix) >> File "src/plugins/tool/ReorderIds.py", line 179, in reorder >> match = _findint.match(gramps_id) >> TypeError: expected string or buffer >> >> OK, nothing concrete (very very hypothetical) and this should be >> fixed by repair tools. Same idea for others objects. Maybe I should >> look at many GEDCOMs for a possible error !!! >> > |