code: def add_size_info (self):
          
          if self.is_directory():
              # Directory size always differs from the customer index.html
              # that is generated. So return without calculating any size.
              return
          filename = self.get_os_filename()
          self.size = fileutil.get_size(filename)
          self.modified = datetime.utcfromtimestamp(fileutil.get_mtime(filename))
docs: Get size of file content and modification time from filename path.