def setdefault(self, key, default=None):
        """Similar to :meth:`dict.setdefault`."""

        try:
            return self[key]
        except (__HOLE__, IndexError):
            self[key] = default
        return default
dataset/ETHPy150Open spacetelescope/PyFITS/pyfits/header.py/Header.setdefault