How to get a context from a json dump

def from_json(cls, json_dump):
        """
        How to get a context from a json dump
        """
        context = cls()
        if json_dump is None:
            return None
        ctxt = json.loads(json_dump)
        for k in ctxt:
            context[k] = ctxt[k]
        return context