Skip to content

Cherry-pick #863: QuiltView import Surname (fork validation) - #15

Merged
eduralph merged 1 commit into
maintenance/gramps60from
cherry/863-quiltview-surname-on-maint
May 17, 2026
Merged

Cherry-pick #863: QuiltView import Surname (fork validation)#15
eduralph merged 1 commit into
maintenance/gramps60from
cherry/863-quiltview-surname-on-maint

Conversation

@eduralph

Copy link
Copy Markdown
Owner

Cherry-picks the one-line Surname import fix from upstream PR gramps-project#863 onto the fork's maintenance/gramps60 so the testbed CI (Ralphovi/gramps-testbed) can exercise the new QuiltView E2E regression against the fixed code before upstream lands gramps-project#863.

Will be naturally superseded by the next upstream-sync.yml run after gramps-project#863 merges upstream.

🤖 Generated with Claude Code

`QuiltView/QuiltView.py:1266` constructs a fresh `Surname()` to
attach to a new `Name` when adding a child via the editor, but
`Surname` is never imported. Ruff (F821) flags it:

    F821 Undefined name `Surname`
       --> QuiltView/QuiltView.py:1266:26

The file already imports `Person, Family, ChildRef, Name` from
`gramps.gen.lib` — extend that import to include `Surname`. Without
it, the add-child path raises `NameError` instead of opening the
editor.

This PR addresses only the `Surname` F821. Two other F821 sites in
the same file (`displayer` on lines 1239/1241, where the call should
likely be `name_displayer.display(...)` rather than a top-level
`displayer` reference) are real-bug fixes and are deliberately left
out of this surgical lint PR — they need a small behavioural review
of their own.

Verified via `ruff check --select=E9,F63,F7,F82 --no-fix
--exclude='*.gpr.py' QuiltView/` (Surname F821 removed; the two
unrelated `displayer` F821s remain) and `python3 -m py_compile`.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
@eduralph
eduralph merged commit dcc99a1 into maintenance/gramps60 May 17, 2026
@eduralph
eduralph deleted the cherry/863-quiltview-surname-on-maint branch May 26, 2026 23:34
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant