Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. QML and Qt Quick
  4. Sudden QML system issues not solved by reinstall
Forum Updated to NodeBB v4.3 + New Features

Sudden QML system issues not solved by reinstall

Scheduled Pinned Locked Moved Unsolved QML and Qt Quick
6 Posts 3 Posters 94 Views 2 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • S Offline
    S Offline
    SanderVc
    wrote last edited by SanderVc
    #1

    Hi all,

    I am developing a QML application on Arch Linux, using the system-provided qt6 packages.

    During development, at some point, after a crash of my application, I was suddenly unable to start it correctly anymore due to what seems like QML system issues (described below). Interestingly, this was not caused by any code change nor any change to the Qt installation itself.

    The issues I am seeing since then:

    • "QtObject is not a type", referring to the QtObject object type which I thought was pretty fundamental to Qt Quick;
    • "Non-existent attached object", referring to a qml line using "Component.onCompleted:" - suggesting the "Component" attached object does not exist.

    Yes, I did properly import QtQuick in each QML file.

    Interestingly, the exact same codebase runs fine when built:

    • in a docker container with its own Qt library installation;
    • in another Arch Linux system which has the exact same Qt packages installed.

    Even previous versions of my application, which worked fine before, now run into these issues on the affected system.

    I tried:

    • reinstalling qt packages
    • deleting "~/.cache/(my app)" to clear QML cache
    • rebooting
    • running with QML_DISK_CACHE=""

    I tried reducing to a minimal example, but unfortunately, simple minimal QML apps seem to work fine.

    Does anyone have any suggestion about any "stateful" aspects of the Qt / QtQuick installation which may be needing to be cleared in order to solve this issue?

    Thanks and kind regards,

    Sander

    JKSHJ 1 Reply Last reply
    0
    • SGaistS Offline
      SGaistS Offline
      SGaist
      Lifetime Qt Champion
      wrote last edited by
      #2

      Hi,

      I haven't used Arch yet so it might be a silly question but are you sure your reinstalled all Qt packages ? i.e. libs + development packages ?

      Interested in AI ? www.idiap.ch
      Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

      S 1 Reply Last reply
      0
      • SGaistS SGaist

        Hi,

        I haven't used Arch yet so it might be a silly question but are you sure your reinstalled all Qt packages ? i.e. libs + development packages ?

        S Offline
        S Offline
        SanderVc
        wrote last edited by
        #3

        @SGaist Thanks for your response! I reinstalled any and every "qt6-*" package on my system:

        qt6-5compat 6.9.1-1
        qt6-base 6.9.1-5
        qt6-charts 6.9.1-1
        qt6-declarative 6.9.1-2
        qt6-graphs 6.9.1-1
        qt6-imageformats 6.9.1-1
        qt6-location 6.9.1-1
        qt6-multimedia 6.9.1-1
        qt6-multimedia-ffmpeg 6.9.1-1
        qt6-networkauth 6.9.1-1
        qt6-positioning 6.9.1-1
        qt6-quick3d 6.9.1-2
        qt6-quicktimeline 6.9.1-1
        qt6-scxml 6.9.1-1
        qt6-sensors 6.9.1-1
        qt6-serialport 6.9.1-1
        qt6-shadertools 6.9.1-1
        qt6-speech 6.9.1-1
        qt6-svg 6.9.1-1
        qt6-tools 6.9.1-2
        qt6-translations 6.9.1-1
        qt6-virtualkeyboard 6.9.1-1
        qt6-wayland 6.9.1-1
        qt6-webchannel 6.9.1-1
        qt6-webengine 6.9.1-2
        qt6-websockets 6.9.1-1
        qt6-webview 6.9.1-1

        In practice, I would expect the most important one for this issue to be qt6-declarative (QML + Quick).

        1 Reply Last reply
        0
        • SGaistS Offline
          SGaistS Offline
          SGaist
          Lifetime Qt Champion
          wrote last edited by
          #4

          The list looks good... Can you check if there are versions that differs from the other computer you tested ?

          Interested in AI ? www.idiap.ch
          Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

          1 Reply Last reply
          0
          • S Offline
            S Offline
            SanderVc
            wrote last edited by
            #5

            The versions are equal on the other system. And, as I originally posted, the issue appeared suddenly - not after an upgrade of any of these packages.

            I would be thinking about a uninstall -> reinstall instead of reinstalling "in-place" - but that is a bit tricky as the entire KDE desktop depends on these packages.

            Next test I will try is to install the Qt packages into a non-standard directory and try to load them from there, using the same project workdir.

            1 Reply Last reply
            0
            • S SanderVc

              Hi all,

              I am developing a QML application on Arch Linux, using the system-provided qt6 packages.

              During development, at some point, after a crash of my application, I was suddenly unable to start it correctly anymore due to what seems like QML system issues (described below). Interestingly, this was not caused by any code change nor any change to the Qt installation itself.

              The issues I am seeing since then:

              • "QtObject is not a type", referring to the QtObject object type which I thought was pretty fundamental to Qt Quick;
              • "Non-existent attached object", referring to a qml line using "Component.onCompleted:" - suggesting the "Component" attached object does not exist.

              Yes, I did properly import QtQuick in each QML file.

              Interestingly, the exact same codebase runs fine when built:

              • in a docker container with its own Qt library installation;
              • in another Arch Linux system which has the exact same Qt packages installed.

              Even previous versions of my application, which worked fine before, now run into these issues on the affected system.

              I tried:

              • reinstalling qt packages
              • deleting "~/.cache/(my app)" to clear QML cache
              • rebooting
              • running with QML_DISK_CACHE=""

              I tried reducing to a minimal example, but unfortunately, simple minimal QML apps seem to work fine.

              Does anyone have any suggestion about any "stateful" aspects of the Qt / QtQuick installation which may be needing to be cleared in order to solve this issue?

              Thanks and kind regards,

              Sander

              JKSHJ Offline
              JKSHJ Offline
              JKSH
              Moderators
              wrote last edited by
              #6

              @SanderVc said in Sudden QML system issues not solved by reinstall:

              The issues I am seeing since then:

              "QtObject is not a type", referring to the QtObject object type which I thought was pretty fundamental to Qt Quick;
              "Non-existent attached object", referring to a qml line using "Component.onCompleted:" - suggesting the "Component" attached object does not exist.
              

              Do you see those when trying to run your application? Or when trying to edit your application in Qt Creator? (Knowing the difference is important, because they have very different root causes)

              Qt Doc Search for browsers: forum.qt.io/topic/35616/web-browser-extension-for-improved-doc-searches

              1 Reply Last reply
              0

              • Login

              • Login or register to search.
              • First post
                Last post
              0
              • Categories
              • Recent
              • Tags
              • Popular
              • Users
              • Groups
              • Search
              • Get Qt Extensions
              • Unsolved