aboutsummaryrefslogtreecommitdiff
path: root/libs/plugin_python/poetry.lock
diff options
context:
space:
mode:
authorSulfurNitride <SulfurNitride@users.noreply.github.com>2026-05-08 17:33:14 -0500
committerSulfurNitride <SulfurNitride@users.noreply.github.com>2026-05-08 17:33:14 -0500
commit492b32bf3d4410a7dab629315e0ebd8f9346f6b4 (patch)
tree2c709fca611a2dc3c42df391ccc1a27db14ec61a /libs/plugin_python/poetry.lock
parent227be23a0c141690bc7c27dafb9bcdb67f37075a (diff)
profile: guard plugins.txt sync against crash-time rewrites
Bethesda's engine rewrites Plugins.txt as part of its shutdown sequence. On a clean exit it preserves the active set; on a crash it can serialize a partially cleared set — every plugin name still listed, but most without their leading '*'. The previous syncPluginsBack code copied that file back to the profile faithfully, after which refreshESPList + savePluginList re-derived state and persisted the broken active list. NSPBR observed this as 1170 active plugins collapsing to 54. Two independent guards: - afterRun() now skips the post-launch sync when exitCode != 0. Non-zero is a strong "do not trust the prefix file" signal. - syncPluginsBack() compares starred-line counts in candidate vs profile. Refuses the copy when the candidate would drop the active count by more than 30% relative AND more than 10 plugins absolute. Belt and suspenders for cases where the engine catches its own crash and exits 0 anyway. Both guards apply regardless of the VFS bridge state and protect every launch on every modlist. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Diffstat (limited to 'libs/plugin_python/poetry.lock')
0 files changed, 0 insertions, 0 deletions