code: def update_tabs_text(self):
          
          # This is needed to prevent that hanged consoles make reference
          # to an index that doesn't exist. See issue 4881
          try:
              for index, fname in enumerate(self.filenames):
                  client = self.clients[index]
                  if fname:
                      self.rename_client_tab(client,
                                             self.disambiguate_fname(fname))
                  else:
                      self.rename_client_tab(client, None)
          except IndexError:
              pass
docs: Update the text from the tabs.