Reset history plugin state

Sorry for resurrecting an old thread, but did somebody ever write such a PR? I see there are open issues on GitHub. I’m willing to give it a shot but I’d like to avoid duplicating effort.