feat: build-suffix labels for [add] actions; chain RV Interior Expansion after Project RV B42
Label format change ('!missing' actions):
- "add TrueMoozic (renamed from truemusic)" → "add TrueMoozic B42"
- "add truemusic" → "add truemusic B41"
Build context lives in the suffix; the alias-rename hint was redundant
because the user already sees the original mod_id in the warning text.
RV Interior Expansion ordering (B42):
PROJECTRVInterior42 → RVInteriorExpansion → RVInteriorExpansionPart2
map folders: map_distanciado → map_aquatsar → rvupdate → rv2 → Muldraugh, KY
Authors didn't declare loadAfter in mod.info; new modpack rules file
data/modpack_rules/rv_expansion.txt establishes the chain. Triggers fire
when either expansion wsid (3618427553 / 3622163276) is in input.
This commit is contained in:
@@ -87,6 +87,7 @@ def build_warnings(
|
|||||||
wsid_lookup: Dict[str, Tuple[str, str]] | None = None,
|
wsid_lookup: Dict[str, Tuple[str, str]] | None = None,
|
||||||
source_wsids: Dict[str, str] | None = None,
|
source_wsids: Dict[str, str] | None = None,
|
||||||
input_modids: Set[str] | None = None,
|
input_modids: Set[str] | None = None,
|
||||||
|
pz_build: str = "B42",
|
||||||
) -> List[Dict[str, Any]]:
|
) -> List[Dict[str, Any]]:
|
||||||
"""Translate mlos_sort warnings to the SORTOF_DATA WARNINGS shape.
|
"""Translate mlos_sort warnings to the SORTOF_DATA WARNINGS shape.
|
||||||
|
|
||||||
@@ -126,16 +127,15 @@ def build_warnings(
|
|||||||
entry = lookup.get(dep)
|
entry = lookup.get(dep)
|
||||||
if entry:
|
if entry:
|
||||||
wsid, suggested = entry
|
wsid, suggested = entry
|
||||||
# If MOD_ID_ALIASES rewrote the suggestion (B42 user needing
|
# The build suffix tells the user which build the suggested
|
||||||
# B41 mod_id `truemusic` gets `TrueMoozic` instead), surface
|
# wsid is for. Both canonical and MOD_ID_ALIASES branches
|
||||||
# both names so the user understands what's being added.
|
# land on the user's pz_build (the lookup helper already
|
||||||
label = (f"add {suggested}" if suggested == dep
|
# filtered wrong-build wsids out).
|
||||||
else f"add {suggested} (renamed from {dep})")
|
|
||||||
actions.append({
|
actions.append({
|
||||||
"type": "add-wsid",
|
"type": "add-wsid",
|
||||||
"wsid": wsid,
|
"wsid": wsid,
|
||||||
"modId": suggested,
|
"modId": suggested,
|
||||||
"label": label,
|
"label": f"add {suggested} {pz_build}",
|
||||||
})
|
})
|
||||||
else:
|
else:
|
||||||
# No cache hit -> link to Steam Workshop search so the user
|
# No cache hit -> link to Steam Workshop search so the user
|
||||||
@@ -665,6 +665,7 @@ def build_response(
|
|||||||
wsid_lookup,
|
wsid_lookup,
|
||||||
source_wsids=source_wsids,
|
source_wsids=source_wsids,
|
||||||
input_modids=input_modids,
|
input_modids=input_modids,
|
||||||
|
pz_build=pz_build,
|
||||||
)
|
)
|
||||||
if drop_ids:
|
if drop_ids:
|
||||||
kept_warnings: List[Dict[str, Any]] = []
|
kept_warnings: List[Dict[str, Any]] = []
|
||||||
|
|||||||
@@ -342,11 +342,18 @@ _MODPACK_RULES_TRIGGERS: Dict[str, str] = {
|
|||||||
# HellDrinx FULL + LITE both bundle the same sorting_rules.txt.
|
# HellDrinx FULL + LITE both bundle the same sorting_rules.txt.
|
||||||
"3672556207": "helldrinx.txt", # HellDrinx FULL
|
"3672556207": "helldrinx.txt", # HellDrinx FULL
|
||||||
"3662909244": "helldrinx.txt", # HellDrinx LITE
|
"3662909244": "helldrinx.txt", # HellDrinx LITE
|
||||||
|
# RVInteriorExpansion + Part2 chain after PROJECTRVInterior42.
|
||||||
|
# Expansion authors didn't declare loadAfter in their mod.info; without
|
||||||
|
# these rules sortof has no signal to chain the cluster.
|
||||||
|
"3618427553": "rv_expansion.txt", # RVInteriorExpansion (rvupdate)
|
||||||
|
"3622163276": "rv_expansion.txt", # RVInteriorExpansionPart2 (rv2)
|
||||||
}
|
}
|
||||||
# Human-readable trigger labels for the warning message.
|
# Human-readable trigger labels for the warning message.
|
||||||
_MODPACK_RULES_LABELS: Dict[str, str] = {
|
_MODPACK_RULES_LABELS: Dict[str, str] = {
|
||||||
"3672556207": "HellDrinx FULL",
|
"3672556207": "HellDrinx FULL",
|
||||||
"3662909244": "HellDrinx LITE",
|
"3662909244": "HellDrinx LITE",
|
||||||
|
"3618427553": "RV Interior Expansion",
|
||||||
|
"3622163276": "RV Interior Expansion Part 2",
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
19
data/modpack_rules/rv_expansion.txt
Normal file
19
data/modpack_rules/rv_expansion.txt
Normal file
@@ -0,0 +1,19 @@
|
|||||||
|
; RV Interior Expansion (B42) — bundled sorting_rules.txt
|
||||||
|
; Triggers:
|
||||||
|
; - 3618427553 (RVInteriorExpansion, map folder rvupdate)
|
||||||
|
; - 3622163276 (RVInteriorExpansionPart2, map folder rv2)
|
||||||
|
; Auto-injected by app.py:_modpack_rules_for() when either trigger wsid is
|
||||||
|
; in the user's input. User-supplied rules are appended afterward and
|
||||||
|
; override these on conflicting keys.
|
||||||
|
;
|
||||||
|
; Authored ordering: PROJECTRVInterior42 → RVInteriorExpansion → RVInteriorExpansionPart2.
|
||||||
|
; The expansion mods don't declare these loadAfter relationships in their own
|
||||||
|
; mod.info, so without these rules sortof has nothing to base the cluster
|
||||||
|
; ordering on (PROJECTRVInterior42 is in PREORDER slot 7 already; expansions
|
||||||
|
; just need to chain off of it).
|
||||||
|
|
||||||
|
[RVInteriorExpansion]
|
||||||
|
loadAfter=PROJECTRVInterior42
|
||||||
|
|
||||||
|
[RVInteriorExpansionPart2]
|
||||||
|
loadAfter=RVInteriorExpansion
|
||||||
Reference in New Issue
Block a user