Bug 443903 - "QML module not found" in IDE
Summary: "QML module not found" in IDE
Status: REPORTED
Alias: None
Product: libplasma
Classification: Frameworks and Libraries
Component: components (show other bugs)
Version: unspecified
Platform: Other Linux
: NOR normal
Target Milestone: ---
Assignee: Marco Martin
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2021-10-17 19:20 UTC by Kristen McWilliam
Modified: 2021-10-19 15:50 UTC (History)
3 users (show)

See Also:
Latest Commit:
Version Fixed In:
Sentry Crash Report:


Attachments
qtcreator error (54.78 KB, image/png)
2021-10-18 00:29 UTC, Kristen McWilliam
Details
kdevelop error (118.56 KB, image/png)
2021-10-18 00:30 UTC, Kristen McWilliam
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Kristen McWilliam 2021-10-17 19:20:41 UTC
IDE is apparently unable to import plasmoid:

`import org.kde.plasma.plasmoid 2.0`

> QML module not found (org.kde.plasma.plasmoid).

Same experience in QtCreator & KDevelop. This doesn't affect the build, only working on the source code.


This makes development more difficult, and in particular poses a barrier to potential new contributors since things like IntelliSense, Go To Definition, quick docs, etc will not work.

So far the only insight to the issue has been:

> "That module is only present if you're running in a Plasmashell context"

Is there any way to resolve this?
Comment 1 Nate Graham 2021-10-17 22:48:13 UTC
Where do you see this error exactly?
Comment 2 Kristen McWilliam 2021-10-18 00:28:30 UTC
A few examples:


plasma-desktop:
containments/desktop/package/contents/ui/main.qml
applets/keyboardlayout/contents/ui/main.qml


plasma-workspace:
components/containmentlayoutmanager/qml/BasicAppletContainer.qml


kweather:
plasmoid/package/contents/ui/main.qml


So far every instance I have checked has the same issue.
Comment 3 Kristen McWilliam 2021-10-18 00:29:50 UTC
Created attachment 142556 [details]
qtcreator error
Comment 4 Kristen McWilliam 2021-10-18 00:30:19 UTC
Created attachment 142557 [details]
kdevelop error
Comment 5 Nate Graham 2021-10-18 15:33:01 UTC
That's funny, I don't see those messages in Kate.
Comment 6 Kristen McWilliam 2021-10-18 16:09:26 UTC
Same, and I don't see them in VSCode either.

Despite the missing error, do you get any sort of intelligent parsing of doc comments, autocomplete suggestions, go to definition for the things plasmoid imports?
Comment 7 Nate Graham 2021-10-19 13:26:27 UTC
I do not