For troubleshooting purposes, I want to temporarily disable all addons, and then re-enable them after running some tests. Any easy way to do this other than manually?
Blender has a module it uses for addon management called addon_utils, this isn't in the API docs and is only for internal usage. But its a fairly straightforward module.
Disable all addons
Will call unregister on all registered addons.
from addon_utils import disable_all disable_all()
Reset all addons
from addon_utils import reset_all reset_all()
both two liners can be run from text editor, or python console.