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

Qt Quick Local Storage does not work with absolute paths

    XMLWordPrintable

Details

    • All
    • 33fbb6ce74 (qt/qtdeclarative/dev) 33fbb6ce74 (qt/tqtc-qtdeclarative/dev) 73188102ef (qt/qtdeclarative/6.4) 73188102ef (qt/tqtc-qtdeclarative/6.4) 42c2e3e2dd (qt/tqtc-qtdeclarative/6.2) 912cea581a (qt/qtdeclarative/6.3)

    Description

      Documentation on Local Storage states the following:

      identifier is the name of the physical file (with or without full path) containing the database

      This is a lie. QQmlLocalStorage::openDatabaseSync method ALWAYS calls QQmlEngine::offlineStorageDatabaseFilePath which ALWAYS prepends QQmlEnginePrivate::offlineStorageDatabaseDirectory to the MD5 hash of the so called "file name". Which means identifier is as far from actual full path as it could possibly be.

      Very sad that documentation is misleading, and I had to spend time browsing Qt source code to find out the reason why database with reported file:///C:/Users/ratijas/Documents/MyApp.db URL isn't shared between two apps from the same workspace.

      Also, very bad that absolute and relative paths or URLs are not supported.

      Attachments

        For Gerrit Dashboard: QTBUG-95232
        # Subject Branch Project Status CR V

        Activity

          People

            qtqmlteam Qt Qml Team User
            ratijas ivan tkachenko
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Gerrit Reviews

                There are no open Gerrit changes