It would be nice to avoid having every error block have a call to both `write_particle_restart` and `fatal_error`. It looks like you did try that already but then had to abort plan due to circular dependencies. Could you add another subroutine elsewhere to wrap these two together? Just seems like this is repeated all over now...