Other places in Bcfg2 do:

    try:
        import json
        # py2.4 json library is structured differently
        json.loads  # pylint: disable=W0104
    except (ImportError, AttributeError):
        import simplejson as json

...in order to be as flexible as possible and work with either json or simplejson.