GP-6288: PyGhidra now by default restores sys.modules each time a script

is run, or the interactive interpreter is reset.

Can be disabled by uncommenting
"#VMARGS=-Dpyghidra.sys.modules.restore.disable=true" in
launch.properties if its found to cause problems.
This commit is contained in:
Ryan Kurtz
2026-01-06 06:11:09 -05:00
parent 78a9822a99
commit d5b9582fd5
3 changed files with 11 additions and 5 deletions

View File

@@ -159,7 +159,6 @@ VMARGS=--enable-native-access=ALL-UNNAMED
# Disables the loaders echoing their message log to the application.log file
#VMARGS=-Ddisable.loader.logging=true
# Restores sys.modules to its prior state after a PyGhidra script is run so the next time the script
# is run, it freshly reloads all of its imported modules again. This is experimental and should only
# be enabled if necessary.
#VMARGS=-Dpyghidra.sys.modules.restore=true
# Prevents PyGhidra from restoring sys.modules to its original state after a PyGhidra script is run.
# Used to help debug potential issues that might arise from mucking with sys.modules.
#VMARGS=-Dpyghidra.sys.modules.restore.disable=true