I recall reading something about custom elective succession laws based on tanistry and/or elective gavelkind forcing the title holder's dynasty members always being candidates. Try putting always = no
and see if all candidates are still there.
I've had a similar issue in the past with another law when using Tanistry as the base, which I thought was due to scripting issues on my part (though I never figured out what was incorrect...), so that might be it. I'll need to investigate this further.
If Tanistry indeed forces every (gender law permitting) dynasty member (that's not explicitly disinherited) into the candidate pool even when they fail to pass the candidate_trigger, then a couple of more important checks might also be broken here (particularly a crucial check for very specific patrilineal descent)... and, more generally, there's the question as to whether other stuff like "Is not in line to inherit a republic" also is broken, which would be
lovely...
Do you happen to know how wide the widest possible Feudal Elective pool is within the same dynasty (ignoring claimants; the held religion head title is unclaimable and should follow the empire title)? Ending up with a non-dynastic Primogeniture fallback would be a major problem, so maybe the "Make the AI unwilling to vote for the people that should be ineligible" fallback is necessary, even if not ideal....
Edit: Okay, so testing some things here:
- I added a new FROM = { trigger_if = { limit = { female = yes } always = no } }. Women are still eligible.
- Converting the relevant woman to Buddhist with the console removes her after running recalc_succ (and possibly over time; I'm testing this with the game paused) or when trying to change my vote to support her, but I can still see her in the candidate list (trying to nominate her if she's not already backed does nothing, so there's some sanity check here; probably the rel head title's inherent functionality).
- I changed the prior addition to is_adult = no instead of female = yes and restarted the game. Children are still eligible, and me backing them does not cause a sanity check.
- I replaced the addition with FROM = { culture = greek }; Japanese characters remain eligible.
- I replaced the addition with a completely nonsensical FROM = { NOT = { dynasty = ROOT } }. Nobody is disqualified.
- Adding the Bastard trait to the woman disinherits her when I try to support her, as expected. She remains in the list of candidates, however.
- Adding the Blinded trait to the woman and changing my culture to Greek disinherits her, as expected. Again, she remains in the candidate list.
- Moving the whole candidate_trigger (restored to its original state) to the allow in a dummy targeted_decision (swapping ROOT and FROM and removing some stuff checking the title) makes the dummy decision's allow block pass
only on the characters it is supposed to (i.e. those that are supposed to be eligible to pass candidate_trigger), and thanks to show_only_failed_conditions = yes I can see that the original woman only fails due to her marriage which indeed should be her sole disqualifier. In addition to this, some other characters fail for other reasons that match with what would be expected.
- Changing the base_type to feudal_elective (after restoring the candidate_trigger) disqualifies
everyone, resulting in (in this case non-dynastic) Primogeniture. Not sure what's up with that; several characters should be eligible, e.g. the siblings of the title holder.
You had
one job, candidate_trigger!