code: def stat(self, filename, timeout=None):
      
      transport = StatFilesyncTransport(self.stream)
      transport.write_data('STAT', filename, timeout)
      stat_msg = transport.read_message(timeout)
      stat_msg.assert_command_is('STAT')
      return DeviceFileStat(filename, stat_msg.mode, stat_msg.size, stat_msg.time)
docs: Return device file stat.