mods sweep doesn't clean orphaned overrides under Mods/UserCode/AutoGen/ #2
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally filed by @coilysiren on 2026-04-28T07:26:43Z - https://github.com/coilysiren/eco-cycle-prep/issues/5
When a mod is removed from the install (via
coily mods-disable, or by manually rming its UserCode folder), AutoGen overrides that the mod owned are left behind underMods/UserCode/AutoGen/{Food,Tool,Vehicle,WorldObject}/*.override.cs.unzip -oon the next mod sync doesn't touch them, andmods.disable_on_serveronly deletes the named UserCode folder.Concrete leftovers found on kai-server (
/home/kai/Steam/steamapps/common/EcoServer/):Mods/UserCode/AutoGen/WorldObject/Arrastra.override.cs- referencesWoodenGearItem, no source equivalent in eco-mods locally.Mods/UserCode/AutoGen/WorldObject/MechanicalWaterPump.override.cs- same.Local eco-mods has
Mods/UserCode/AutoGen/{Food,Tool,Vehicle}/only, noWorldObject/subdir, so the entire server-sideWorldObject/dir is orphan.Update 2026-05-01: the original report also flagged
Mods/UserCode/DFEasierShopCart/as source-removed-but-server-resident. That was a misobservation - the mod is and was tracked in eco-mods atMods/UserCode/DFEasierShopCart/(commit 0e1d9b1). Not an orphan. The AutoGenWorldObject/orphans are still real.Proper fix probably belongs in
eco_cycle_prep/mods.py: extenddisable_on_server(or add a sibling sweep) that walks the serverMods/UserCode/AutoGen/tree and removes any*.override.cswhose owning mod is no longer present, plus prunes the source mod folder. Or rsync-with-delete from a known-good source manifest.Tonight's workaround (one-off cleanup folded into
infrastructure/scripts/install-eco-mod.sh) needs to come back out once a real sweep is in place.