hgbuildbot.py: make it compatible with both mercurial 0.9.1 and the current 0.9.4