title: Add async data to QTableView with PyQt5
body: <p>I would like to add async data to a QTableView without blocking and showing a fallback text like &quot;Loading...&quot; in the cell while it's retrieving the data.</p>
  <p>I wonder if it's even possible with PyQt5...</p>
  <p>That's what I have at the moment and obviously it doesn't work:</p>
  <pre class="lang-py prettyprint-override"><code>import asyncio
  import random
  import string
  import sys
  from PyQt5 import QtCore, QtGui, QtWidgets
  from PyQt5.QtCore import Qt
  
  
  class Item:
      @property
      def name(self):
          return ''.join(random.choice(string.ascii_letters) for _ in range(10))
      
      async def get_data_from_slow_api(self):
          await asyncio.sleep(5)
          return &quot;Lorem ipsum&quot;
  
  
  class TableModel(QtCore.QAbstractTableModel):
      def __init__(self, data):
          super(TableModel, self).__init__()
          self._data = data
  
      def data(self, index, role):
          if role == Qt.DisplayRole:
              return self._data[index.row()][index.column()]
  
      def rowCount(self, index):
          return len(self._data)
  
      def columnCount(self, index):
          return len(self._data[0])
  
  
  class MainWindow(QtWidgets.QMainWindow):
      def __init__(self):
          super().__init__()
          self.table = QtWidgets.QTableView()
          item1 = Item()
          item2 = Item()
          item3 = Item()
          item4 = Item()
          data = [
              [item1.name, item1.get_data_from_slow_api()],
              [item2.name, item2.get_data_from_slow_api()],
              [item3.name, item3.get_data_from_slow_api()],
              [item4.name, item4.get_data_from_slow_api()],
          ]
          self.model = TableModel(data)
          self.table.setModel(self.model)
          self.setCentralWidget(self.table)
  
  
  if __name__ == &quot;__main__&quot;:
      app=QtWidgets.QApplication(sys.argv)
      window=MainWindow()
      window.show()
      app.exec_()
  </code></pre>