webtrees icon indicating copy to clipboard operation
webtrees copied to clipboard

update for german relationships

Open arbor95 opened this issue 6 months ago • 11 comments

arbor95 avatar May 13 '25 18:05 arbor95

Codecov Report

:x: Patch coverage is 0% with 128 lines in your changes missing coverage. Please review. :white_check_mark: Project coverage is 34.97%. Comparing base (ef7460e) to head (f383b1a).

Files with missing lines Patch % Lines
app/Module/LanguageGerman.php 0.00% 128 Missing :warning:
Additional details and impacted files
@@             Coverage Diff              @@
##               main    #5150      +/-   ##
============================================
- Coverage     35.06%   34.97%   -0.10%     
- Complexity    11204    11208       +4     
============================================
  Files          1161     1161              
  Lines         48477    48605     +128     
============================================
  Hits          17000    17000              
- Misses        31477    31605     +128     

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.

:rocket: New features to boost your workflow:
  • :snowflake: Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • :package: JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

codecov[bot] avatar May 16 '25 11:05 codecov[bot]

Hi @arbor95 - thanks for this!

I have made some small changes, to fix the tests and code-style.

You have a function $genitive($prefix, $suffix, $gender).

If $gender is male/female/unknown, then it would be clearer to use 'M'/'F'/'U' instead of 0/1/2 The logic for 1 and 2 is the same. Is this correct?

fisharebest avatar May 16 '25 11:05 fisharebest

0 = M 1 = F 2 = independent (I did not distinguish. its only used once for ->descendant() )

yes that can be simplyfied cause 1 and 2 is equal code.

arbor95 avatar May 16 '25 12:05 arbor95

I think we are missing definitions for cousins.

fisharebest avatar May 30 '25 14:05 fisharebest

I think we are missing definitions for cousins.

Do you mean my code? There are line 129 to 132!

arbor95 avatar May 30 '25 17:05 arbor95

Those are just simple "first cousins" (same grandparents).

What about cousins where the common ancestors are more generations?

Most languages have a relationship "Nth cousin" or "cousin of the Nth degree". But the rules for calculating "N" are different in each language.

fisharebest avatar May 31 '25 17:05 fisharebest

The English cousin names are very complicated. Others, such as Italian, are much simpler.

fisharebest avatar May 31 '25 17:05 fisharebest

See this line in the English definitions:

Relationship::dynamic($cousin)->ancestor()->sibling()->descendant(),

fisharebest avatar May 31 '25 17:05 fisharebest

AfaIk there is no special naming in german language.

arbor95 avatar Jun 02 '25 10:06 arbor95

AfaIk there is no special naming in german language.

At present, German uses a similar system to Engish

First cousin (same grandparents) => Cousin 1. Grades Second cousin (same great-grandparents) => Cousin 2. Grades Third cousin (same great-great-grandparents) => Cousin 3. Grades

Should we keep this, or use "Cousin/e" for every type of cousin?

When cousins are not "symmetrical", English uses "removed ascending" and "removed descending".

German currently uses the same system, translating it as "Cousin 3 grades 2. Grades in aufsteigender Folge"

I asked ChatGPT (!), and is says German uses only symmetrical cousins. e.g. Grandparent's Cousin, or Cousin's child.

fisharebest avatar Jun 03 '25 11:06 fisharebest

I do not use and do not know (its not common usage), neither symmetrical nor asymetrical. The current translation is only a 1:1 copy of the original english, I think nobody was interested in that relations (its theoretical).

instead of "second cousin once removed ascending’s husband" the now implemented "Schwiegersohn der Tochter des Urgroßonkels" is ok. Vesta says for "second cousin once removed ascending’s husband" the above in German "Ehemann der Tante 3. Grades" (direct translation is "husband of aunt 3. degree" <-> "third aunt's husband")


"Ururgroßnichte des Urgroßvaters (väterlicherseits)" I like more than "third cousin once removed descending" while vesta simply says "Nichte 4. Grades"


I do not think ChatGPT is the expert and I'd say its wrong.

arbor95 avatar Jun 03 '25 17:06 arbor95

What is missing to get this pull request into the webtrees code?

arbor95 avatar Aug 16 '25 12:08 arbor95