Uploaded image for project: 'Qt'
  1. Qt
  2. QTBUG-28592

assistant crashes while trying to update the search index, if qch docs were regenerated

    XMLWordPrintable

Details

    • Bug
    • Resolution: Done
    • P2: Important
    • 5.0.0
    • 5.0.0
    • Tools: Assistant
    • None
    • Arch Linux 64-bit
    • 1ee2a1c1be22485b46021b3ec7a5f4ebca3a5c92

    Description

      I'm not sure how to reproduce this on-demand but I've seen it happen several times when I update my git tree and then rebuild docs (make qch_docs) and then try to run assistant. A Lucene exception is thrown and isn't caught, so it crashes assistant. I can fix it by doing

      rm -rf /home/rutledge/.local/share/QtProject/Assistant/.qthelpcollection_5.0.0/

      At one point in the stack I find this constructor

      QCLuceneIndexSearcher::QCLuceneIndexSearcher(const QString &path)
      : QCLuceneSearcher()
      {
      lucene::search::IndexSearcher *searcher =
      new lucene::search::IndexSearcher(path);

      reader.d->reader = searcher->getReader();
      reader.d->deleteCLuceneIndexReader = false;

      d->searchable = searcher;
      }

      so it's possible to add a try-catch around this code and catch the exception, but other callers later expect d->searchable to be non-null, so if it can be null then some checks have to be added. Other places it's not possible to catch exceptions because we have them turned off.

      Attachments

        No reviews matched the request. Check your Options in the drop-down menu of this sections header.

        Activity

          People

            heimrich Karsten Heimrich
            srutledg Shawn Rutledge
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Gerrit Reviews

                There are no open Gerrit changes