Skip to content

Commit

Permalink
Translation fixes in probably alive code
Browse files Browse the repository at this point in the history
Remove ":s" from format strings, which is preventing the
"python-brace-format" flag from being added to the strings.

Also remove a space from a string which is almost a duplicate of
another string.

Fixes #13604.
  • Loading branch information
Nick-Hall committed Feb 6, 2025
1 parent 7e7b84c commit aa19049
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions gramps/gen/utils/alive.py
Original file line number Diff line number Diff line change
Expand Up @@ -260,7 +260,7 @@ def get_person_bd(class_or_handle):
birth_evidence_direct = True
if death_date is not None:
explanation = _(
"Direct evidence for this person - birth: {birth_min_src:s}, death: {death_src:s}"
"Direct evidence for this person - birth: {birth_min_src}, death: {death_src}"
).format(
birth_min_src=explain_birth_min,
death_src=explain_death,
Expand Down Expand Up @@ -438,21 +438,21 @@ def get_person_bd(class_or_handle):
# or else both are zero (if None then it's a bug).
if birth_evidence_direct:
explanation = _(
"Direct evidence for this person - birth: {birth_min_src:s}, death: {death_src:s}"
"Direct evidence for this person - birth: {birth_min_src}, death: {death_src}"
).format(
birth_min_src=explain_birth_min,
death_src=explain_death,
)
elif explain_birth_max == "":
explanation = _(
"inferred from parents and siblings - birth: {birth_min_src:s}, death: {death_src:s}"
"inferred from parents and siblings - birth: {birth_min_src}, death: {death_src}"
).format(
birth_min_src=explain_birth_min,
death_src=explain_death,
)
else:
explanation = _(
"inferred from parents and siblings - birth: {birth_min_src:s} (earliest) to {birth_max_src:s} (latest), death: {death_src:s}"
"inferred from parents and siblings - birth: {birth_min_src} (earliest) to {birth_max_src} (latest), death: {death_src}"
).format(
birth_min_src=explain_birth_min,
birth_max_src=explain_birth_max,
Expand Down

0 comments on commit aa19049

Please sign in to comment.