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

qmlls formatting is slow

    XMLWordPrintable

Details

    • Suggestion
    • Resolution: Fixed
    • P2: Important
    • 6.8
    • 6.7.2
    • QML: Tooling
    • None

    Description

      We got feedback that `qmlls` formatting is slow in this bug report https://bugreports.qt.io/browse/VSCODEEXT-85

      I tested with both the `qmlformat` executable and the formatting in the vscode extension with `qmlls`

      The `qmlformat` results are like below
      ```

      > time /Users/orkun/Qt/6.7.2/macos/bin/qmlformat Main.qml --i

      ________________________________________________________
      Executed in   65.20 millis    fish           external
         usr time   43.54 millis    0.21 millis   43.34 millis
         sys time   14.27 millis    1.54 millis   12.73 millis

      ```

      I formatted the same file and recorded my screen because I couldn't find any tool to measure it. It seems like it takes between 1-2 seconds.

      What could be the root cause of this? Do you think there is a way to improve it?

      The test file is `Main.qml` in the calculator example. I copied some properties to make it big.

       

      Main.qml

       

      Attachments

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

        Activity

          People

            semih.yavuz Semih Yavuz
            orkun.tokdemir Orkun Tokdemir
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Gerrit Reviews

                There are no open Gerrit changes