Shane Jaroch [Thu, 22 Jan 2026 22:01:33 +0000 (17:01 -0500)]
Major refactor: Typer CLI, comprehensive tests, and CI improvements
- Migrate CLI to Typer for tab completion and better argument handling
- Split tree.py into modular tree/ package (core, records, elements, utils)
- Add comprehensive test suite with merge idempotency, session caching, etc.
- Add offline test fixtures via git submodule (res/testdata)
- Set up GitHub Actions CI with Coveralls integration
- Add git-sqlite-filter for reproducible SQLite fixture handling
- Improve merge deduplication for names, facts, notes, and sources
- Fix session cookie/caching and rate limiting
- Add Makefile for common dev tasks
Modernizes the tool with a new CLI, faster and safer networking, and a refactored tree/session architecture to improve reliability and performance. Adds CI and tests, and consolidates packaging for easier development.
- **New Features**
- New CLI with exclude list and distance options; UTF‑8-safe output.
- HTTP caching (requests-cache), optional cache-control, and request rate limiting; persistent cookie cache.
- Offline mode to use cached data without logging in.
- Place enrichment via Geonames/geocoder with structured Place objects.
- Clear GUI Tkinter error; first‑run license prompt stored locally.
- Immigration fact mapping and contributor attribution from change logs.
- **Refactors**
- New GMASession with cached session; switched to FS IDs; tree split into elements/records; legacy getmyancestors.py removed; entry points updated.
- Added unit/integration tests and GitHub Actions (Linux/macOS/Windows); Makefile targets; linting/formatting gates.
- Dependencies consolidated in pyproject; added requests-cache, requests-ratelimiter, geocoder; removed requirements.txt.
- Fixed merge duplication; idempotent merges via set-based dedup in mergemyanc.
changeling [Wed, 9 Feb 2022 23:43:35 +0000 (17:43 -0600)]
Add newline to class.gedcom and adjust imports
Add newline before class definition in gedcom.py
Add class import of Ordinance to gedcom.py
Add constant import of ORDINANCES to gedcompy
Remove unnecessary imports from getmyancestors.py
changeling [Wed, 9 Feb 2022 08:28:58 +0000 (02:28 -0600)]
Split classes.py into separate modules.
Create gui.py, session.py, tree.py, gedcom.py.
Update version to 1.0.2-rc.2.
Add classes directory to setup.cfg.
Fred Wright [Tue, 19 Jan 2021 02:59:55 +0000 (18:59 -0800)]
[IMP] Direct informational messages to stderr.
This allows the GEDCOM output to be piped to another program without
polluting it with progress messages.
The usage text is now also directed to stderr, as is normal practice.
TESTED:
Piped output to an editor, with the progess messages still appearing
on the terminal.
Usage text now appears on the terminal, even with redirected stdout.
Fred Wright [Sun, 5 Jan 2020 23:25:23 +0000 (15:25 -0800)]
Tolerate inability to write settings file.
It's questionable that the unsolicited write of the settings is
reasonable at all, but at the very least it shouldn't crash if it
can't, e.g., when outputting to /dev/null for testing.
TESTED:
Now prints message and continues on failed attempt to write
/dev/null.settings. Writes settings successfully with real
output file specified.
changeling [Wed, 27 Mar 2019 00:05:56 +0000 (19:05 -0500)]
Update .settings file handling and defaults.
Handle non-argparse `username` and `password`.
Removed printing of settings to stdout.
Remove `redact_password = True` line.
Add `--redact-password` argument, defaulting to `False`.
Removed `.settings` file creation when output is directed to stdout.
changeling [Mon, 11 Mar 2019 06:28:54 +0000 (01:28 -0500)]
Update GEDCOM Header in getmyancestors.py for 5.5.1 compliance. (#11)
* Update GEDCOM Header in getmyancestors.py for 5.5.1 compliance.
getmyancestors.py: Add SOUR, SUBM ref and SUBM entry. Update VERS to 5.5.1.
(UTF-8 is only in GEDCOM 5.5.1 and not 5.5, but getmyancestors creates header with VERS 5.5 and encoding UTF-8.)
* Fix Notes: set the text attribute before adding to Tree
* Updated to render correct ordinals in Download progress counts.
fstogedcom.py:
Lines 34-45: Implemented ordinal() function.
Line 441: Yield correct ordinal for ancestor generations.
Line 450: Yield correct ordinal for descendant generations.
getmyancestors.py
Lines 107-118: Implemented ordinal() function.
Line: 960: Yield correct ordinal for ancestor generations.
Line 970: Yield correct ordinal for descendant generations.
Fixed string slice in ordinal() to correctly handle 11, 12, 13.
Fixed string slice in ordinal() to correctly handle 11, 12, 13 in fstogedcom.py and getmyancestors.py.
* Replaced ordinal() function and calls with num2word module and calls.
Replaced ordinal() function and calls with num2word module and calls in fstogedcom.py and getmyancestors.py.
Removed ordinal suffixes from translation.py.
* Update README.md to reference num2words and github repository.
Added num2words requirement to README.md.
Add references for github repository to README.md.
* Update getmyancestors.py to add more 5.5.1 HEAD entries.
Add display_name to Session().
Assign display_name from current.json ['users'][0]['displayName'].
Add 'getmyancestors' value for HEAD.SOUR, HEAD.SOUR.NAME, HEAD.DEST. See:
https://www.tamurajones.net/GEDCOMSOURandDEST.xhtml for discussion.
Add HEAD.SOUR.VERS with placeholder value for version.
Add HEAD.DATE and HEAD.TIME.
Add SUBM.NAME from Family Search displayName for current user.
Add SUBM.LANG from Family Search displayName for current user. NOTE: This value is invalid.
TODO: Fix 2-char lang value to full language name for legal GEDCOM.
* Update getmyancestors.py to correct SUBM.LANG format.
Added import of babelfish to handle language formats.
Added babelfish conversion to SUBM.LANG to convert alpha2 language code (i.e. `en`) from Family Search to legal GEDCOM language code (i.e. `ENGLISH`).
Updated README.md to include reference to babelfish module.
* Revert "Merge pull request #9 from changeling/handle_ordinals"
* Change information text about downloading generations
* Update GEDCOM Header in getmyancestors.py for 5.5.1 compliance.
getmyancestors.py: Add SOUR, SUBM ref and SUBM entry. Update VERS to 5.5.1.
(UTF-8 is only in GEDCOM 5.5.1 and not 5.5, but getmyancestors creates header with VERS 5.5 and encoding UTF-8.)
* Update getmyancestors.py to add more 5.5.1 HEAD entries.
Add display_name to Session().
Assign display_name from current.json ['users'][0]['displayName'].
Add 'getmyancestors' value for HEAD.SOUR, HEAD.SOUR.NAME, HEAD.DEST. See:
https://www.tamurajones.net/GEDCOMSOURandDEST.xhtml for discussion.
Add HEAD.SOUR.VERS with placeholder value for version.
Add HEAD.DATE and HEAD.TIME.
Add SUBM.NAME from Family Search displayName for current user.
Add SUBM.LANG from Family Search displayName for current user. NOTE: This value is invalid.
TODO: Fix 2-char lang value to full language name for legal GEDCOM.
* Update getmyancestors.py to correct SUBM.LANG format.
Added import of babelfish to handle language formats.
Added babelfish conversion to SUBM.LANG to convert alpha2 language code (i.e. `en`) from Family Search to legal GEDCOM language code (i.e. `ENGLISH`).
Updated README.md to include reference to babelfish module.
* Updated `README.md` and `getmyancestors.py` re 5.5.1.
`getmyancestors.py`:
Remove `DEST` tag.
Set `SOUR.VERS` to 1.0.
Implement `babelfish` module to correct FamilySearch `LANG` to match iso639 full language for 5.5.1 compliance.
`README.md`.:
Add babelfish.
Modify requirement install instruction for readability and line length re PEP 8.
Add github Issues link.
* Revert "Merge branch '551_compliance' of https://github.com/changeling/getmyancestors into 551_compliance"