-
Notifications
You must be signed in to change notification settings - Fork 118
Gedcom 7 import plugin #744
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: maintenance/gramps60
Are you sure you want to change the base?
Gedcom 7 import plugin #744
Conversation
This comment was marked as outdated.
This comment was marked as outdated.
In a Discourse "Idea" and related feature request, Woody notes that GedTool (VBA software $35) uses a "mapping table" GEDCOM dialect lookup file to map which importer to use. This differentiates between 5.5.x and 7.x and originating software. https://gramps.discourse.group/t/new-gedcom-import-module/7045 There are other formats that could also benefit from version recognition branching. The built-in vCard importer only recognizes v3.0 (and only a limited subset) but many Smartphones only export v2.1 |
The format version (e.g. "7.0") is required in the header in the Gedcom 7 specificiation so detecting it is trivial, the problem is just that this would require a change in Gramps core. |
I guess I am stupid, but I cannot see how to test (on Mac). I copied the ImportGedcom7 folder to my gramps60/plugins folder. Copied your maximal70.ged (to maximal70.ged7). Then went to FamilyTrees --> Import but gramps does not seem to find the new import type (ged7). I tried both with and without the standalone (gramps-gedcom7) library - expected error on import without it. No warnings/errors in the console, so I suspect it is not installed correctly. |
Does GEDCOM 7 show up in the "Select file type" drop down in the file dialog? (Note: I was first confused because I had to scroll that dialog to see the last, new entry.) |
Was anyone else able to test this? Perhaps it's a Mac issue? I noticed that this behaviour (Gedcom 7 not offered in the file dialog) happens when the library is not installed or not detected. |
I was expecting an error if the library was not installed in the line:
but didnt get any. I tried with and without the library installed - no difference. I put the gramps_gedcom7 folder in the same plugins folder (since Mac uses a bundle) |
I think the reason there is no error is that the module is listed as |
D'ohhhh I manually installed gramps_gedcom7 not using pip (given gramps on a Mac is a bundle, any additional packages need to be added to the bundle and not to the standard OS). So I did not load gedcom7 package. Once I also loaded gedcom7 v0.4.0, things worked. |
Did anyone have a chance to play around? How should I deal with the extension issue, should be advise users to rename their files? |
Maybe adapt the suggestion at the end this article?
Another way is to look at how the GEDCOM Extensions addon handles exports and see the enhancement request to refactor it to support imports?
The GEDCOM extension outputs the file to *.ged2 and afterwards, you can change the extension from ".ged2" to ".ged" and treat as a normal GEDCOM file. |
Detecting that a file is GEDCOM7 is easy, the problem is that currently, when it has extension |
Then Gramps core needs to be updated to support the detection or feature 10550 be implemented to monkey patch the Gramps GEDCOM import detection in your addon? |
Deleted the internal GEDCOM 5 importer; but probably could have hidden it via the plugin manager; which could be a suggestion to users of the addon at least during development? Tested using the familysearch ged 7 example files and these so nothing from the wild yet. Thanks for the addon ✨ |
This is a draft of an import plugin for Gedcom 7 files based on the standalone library. The implementation is not complete yet, but ready for testing & feedback.
Two problems regarding the plugin (i.e., independent of the library):
ged
as extension, the plugin is always overruled by the core Gedcom (6) plugin. That's why I had to change the extension toged7
, but that's an ugly hack. Is there a way around it?gramps_gedcom7
(with underscore) torequires_mod
because that's the module that is required, but there are two problems with this:gramps-gedcom7
(with hyphen) and there is currently no way to specify that in thegpr
fileTo install the required package, use