code: def rfc3339(self):
          
          if self._nanosecond == 0:
              return to_rfc3339(self)
          nanos = str(self._nanosecond).rjust(9, '0').rstrip("0")
          return "{}.{}Z".format(self.strftime(_RFC3339_NO_FRACTION), nanos)
docs: Return an RFC 3339-compliant timestamp.
  
          Returns:
              (str): Timestamp string according to RFC 3339 spec.