fix(report): use the upstream reader edition for new longform bodies
New reports request reader_main from upstream origin/main 23b9609e. KP and transit no longer copy an empty vars() dict, solar returns keep birth_asc_sign_idx, and ordinary projection deletes internal lines whole.
This commit is contained in:
+15
-8
@@ -401,6 +401,7 @@ def calc_solar_return_chart(
|
||||
'houses': houses,
|
||||
'ascendant': ascendant,
|
||||
'asc_sign_idx': sr_asc_idx,
|
||||
'birth_asc_sign_idx': birth_asc_idx,
|
||||
'target_year': target_year,
|
||||
'birth_year': birth_year,
|
||||
'age': target_year - birth_year,
|
||||
@@ -505,14 +506,20 @@ def solar_return_full_report(
|
||||
# 3. Year Lord(= Muntha 守护星)
|
||||
try:
|
||||
muntha_data = result.get('muntha', {})
|
||||
muntha_sign_val = muntha_data.get('muntha_sign_idx', muntha_sign if 'muntha_sign' in dir() else 0)
|
||||
year_lord_sign = muntha_sign_val
|
||||
year_lord = SIGN_LORDS[SIGNS[year_lord_sign]]
|
||||
result['year_lord'] = {
|
||||
'year_lord': year_lord,
|
||||
'year_lord_sign_idx': year_lord_sign,
|
||||
'year_lord_sign': SIGNS[year_lord_sign],
|
||||
}
|
||||
muntha_sign_val = muntha_data.get('muntha_sign_idx') if isinstance(muntha_data, dict) else None
|
||||
if not isinstance(muntha_sign_val, int) or isinstance(muntha_sign_val, bool):
|
||||
result['year_lord'] = {
|
||||
'status': 'blocked',
|
||||
'reason': 'muntha_sign_required_for_year_lord',
|
||||
}
|
||||
else:
|
||||
year_lord_sign = muntha_sign_val % 12
|
||||
year_lord = SIGN_LORDS[SIGNS[year_lord_sign]]
|
||||
result['year_lord'] = {
|
||||
'year_lord': year_lord,
|
||||
'year_lord_sign_idx': year_lord_sign,
|
||||
'year_lord_sign': SIGNS[year_lord_sign],
|
||||
}
|
||||
except Exception as e:
|
||||
result['year_lord'] = {'error': str(e)}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user