Save pulse charge in the sample logs

Refs #6871
Add exception handler for std::invalid_argument

Add an exception handler so that we'll get some better log messages if
the live listener background thread ever throws std::invalid_argument.

Refs #6871
Revert "Add an exception handler for std::invalid_argument"

This reverts commit d6e109718e74924305014c81c8de96a0ea0e6b62.
Revert "Save pulse charge in the sample logs"

This reverts commit 5462b9d44da1399e35fe2641ce559c31da4e7d0f.
Merge branch 'feature/6871_save_proton_charge' into develop