TASK-upstream-sync4-20261002 T6, decision 4. Visible parallel calculators were
found in three places and all now read jaimini:
- yogas_doshas.calc_arudha_lagna / calc_upapada_lagna (house number taken as an
Aries-based sign index, no 1/7 exception) are deleted; the module's
arudha_lagna / upapada_lagna fields come from jaimini.
- special_lagnas.calculate_arudha_lagna / calculate_upapada_lagna ("count from
the landing" 1/7 exception, which disagrees with jaimini when the lord is
4th/10th from the source) are deleted; the full reading's Arudha_Lagna /
Upapada_Lagna rows are built from jaimini padas.
- the transit multi-reference table took "ascendant degree + 12th-lord degree"
as AL; it now uses jaimini's A1.
jaimini's own exception counting is unchanged (astrologer question 5); the
upstream "count from the landing" variant is not ported. A10 in special_lagnas
keeps its own exception rule (outside decision 4; listed in progress).
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01N4f2nya58RoRu4yEmJgRGE
42 lines
1.9 KiB
Python
42 lines
1.9 KiB
Python
"""BUG-1190 (TASK-upstream-sync4-20261002 T6): AL / UL have one source.
|
|
|
|
Every place a full reading shows Arudha Lagna or Upapada Lagna (yogas_doshas,
|
|
special_lagnas, the transit multi-reference table) must equal
|
|
``jaimini.calc_arudha_padas``. Fictitious charts only. 00:30 puts the lagna
|
|
lord 4th from the lagna and 02:30 puts the 12th lord 4th from the 12th, the two
|
|
cases where the removed "count from the landing" 1/7 exception disagreed.
|
|
"""
|
|
|
|
from __future__ import annotations
|
|
|
|
import pytest
|
|
|
|
from scripts.jyotish_engine import cmd_full_reading
|
|
from scripts.professional_report_reference import _export_args
|
|
import scripts.special_lagnas as special_lagnas
|
|
import scripts.yogas_doshas as yogas_doshas
|
|
|
|
BASE = dict(year=1990, month=6, day=15, second=0, lat=39.9042, lon=116.4074, tz=8,
|
|
ayanamsa="lahiri", node_mode="mean")
|
|
|
|
|
|
@pytest.mark.parametrize("hour", [10, 0, 2])
|
|
def test_full_reading_al_ul_equal_jaimini(hour: int) -> None:
|
|
modules = cmd_full_reading(_export_args({**BASE, "hour": hour, "minute": 30}))["modules"]
|
|
padas = modules["jaimini"]["arudha_padas"]
|
|
al, ul = padas["arudha_lagna"]["sign"], padas["upapada"]["sign"]
|
|
|
|
assert modules["yogas_doshas"]["arudha_lagna"]["arudha_lagna"] == al
|
|
assert modules["yogas_doshas"]["upapada_lagna"]["upapada"] == ul
|
|
assert modules["special_lagnas"]["Arudha_Lagna"]["sign"] == al
|
|
assert modules["special_lagnas"]["Upapada_Lagna"]["sign"] == ul
|
|
assert modules["special_lagnas"]["Arudha_Lagna"]["source"] == "jaimini.calc_arudha_padas"
|
|
assert modules["transit_multi_reference"]["references"]["Arudha_Lagna"]["sign"] == al
|
|
|
|
|
|
def test_parallel_arudha_calculators_are_gone() -> None:
|
|
assert not hasattr(yogas_doshas, "calc_arudha_lagna")
|
|
assert not hasattr(yogas_doshas, "calc_upapada_lagna")
|
|
assert not hasattr(special_lagnas.SpecialLagnasCalculator, "calculate_arudha_lagna")
|
|
assert not hasattr(special_lagnas.SpecialLagnasCalculator, "calculate_upapada_lagna")
|