<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def get_state(self):
 """Get the state of the MessageSender and its underlying Link. :rtype: ~uamqp.constants.MessageSenderState """

        try:
            raise self._error
        except TypeError:
            pass
        except Exception as e:
            _logger.warning("%r", e)
            raise
        return self._state