I had assumed that I could simply set the onhashchange event handler to null, change the hash, and then set the onhashchange event handler to something, but consider the following code:
window.onhashchange = null;
window.location.hash = "this_should_not_concern_you";
window.onhashchange = function() {alert('chunky bacon')};
doOtherStuff();
So when the has is changed, there's no event handler for hash change, but I still get alerts for "chunky bacon".
Update
I chose to go with the setInterval solution from Jed. And although it works (thank you Jed), it's ugly and brittle. If there was a (somewhat paradoxical) onAllEventsHandled event, then I could put my onhashchange subscription in there and be sure that I'm not accidentally alerting "chunky bacon" just because doOtherStuff() takes 2 seconds to complete.