Details
-
Bug
-
Resolution: Fixed
-
P2: Important
-
6.6
-
None
-
7a4175ff6 (dev)
Description
I have been playing around with qmlls and its document format requests. Here are some unexpected results I encountered.
- After typing out a simple but valid qml file, it is marked as invalid and formatting fails. Invoking qmlformat directly works as expected. See New.{mp4,qml}
- Formatting removes the escape character in the key string of a key-value pair of an object. See Escape.{mp4,qml}
- Some requests cause an assertion failure and then never finish unless interrupted by the user. See Infinite.{mp4,qml}
- Formatting is performed on the last valid state of the document leading to some spooky behavior such as adding additional braces or bringing deleted code back. For some reason, in the example code, the presence of the comment at the end of the line also has an importance in triggering the issue. See Spooky.{mp4,qml}
I have used patchset 10 of semih.yavuz 's work here https://codereview.qt-project.org/c/qt/qtdeclarative/+/475123/10 cherry-picked on top of 36e3ea45f9df38ee0f2e1e619a8c344357d56896 from dev
Attachments
Issue Links
- is required for
-
QTBUG-112977 LSP: Support textDocument formatting
- Closed
- resulted in
-
QTBUG-113776 qmlformat fails to format if there is a escape char in the key string
- Closed
-
QTBUG-113830 qmlls: write tests that simulates a user writing/editing code
- Closed
For Gerrit Dashboard: QTBUG-113725 | ||||||
---|---|---|---|---|---|---|
# | Subject | Branch | Project | Status | CR | V |
479562,11 | qmlls: Fix TextSynchronization | dev | qt/qtdeclarative | Status: MERGED | +2 | 0 |