Posting this for reference.
If a batch Apex process like DLRS updates an inactive sys admin user, NPSP will try to update the Error Settings custom settings by a future method, and that throws an error System.AsyncException: Future method cannot be called from a future or batch method: npsp.USER_UserService.handleDeactivatedSysAdminFuture(Set)
Workaround is to remove all the following permissions from inactive sys admin users:
- Customize Application
- Modify All Data
- Author Apex
The problem is that the method is being called by the trigger when any field is updated, and it doesn't distinguish that a user is already inactive.
Posting this for reference.
If a batch Apex process like DLRS updates an inactive sys admin user, NPSP will try to update the Error Settings custom settings by a future method, and that throws an error System.AsyncException: Future method cannot be called from a future or batch method: npsp.USER_UserService.handleDeactivatedSysAdminFuture(Set)
Workaround is to remove all the following permissions from inactive sys admin users:
The problem is that the method is being called by the trigger when any field is updated, and it doesn't distinguish that a user is already inactive.