| Summary: | KRunner fails to search/list Activities due to kactivitymanagerd SQL syntax error "near '.'" | ||
|---|---|---|---|
| Product: | [Plasma] plasmashell | Reporter: | Simone <simosi1000> |
| Component: | Activities in general | Assignee: | Plasma Bugs List <plasma-bugs-null> |
| Status: | REPORTED --- | ||
| Severity: | normal | CC: | alexander.lohnau, ivan.cukic, kdedev, natalie_clarius, nate, stephan.diestelhorst |
| Priority: | NOR | ||
| Version First Reported In: | 6.5.4 | ||
| Target Milestone: | 1.0 | ||
| Platform: | Arch Linux | ||
| OS: | Linux | ||
| Latest Commit: | Version Fixed/Implemented In: | ||
| Sentry Crash Report: | |||
I see the same thing on KDE Neon with logging via systemd with a fresh database:
syon@d-allen:~$ systemctl --user status plasma-kactivitymanagerd
[...]
Jan 08 11:31:31 d-allen systemd[1941]: Started plasma-kactivitymanagerd.service - KActivityManager Activity manager Service.
Jan 08 11:31:31 d-allen kactivitymanagerd[13706]: SQL:
error: QSqlError("1", "Unable to execute statement", "near \".\": syntax error")
query: ".tables"
Hey, can you do sqlite3 ~/.local/share/kactivitymanagerd/resources/database and type .tables there? Also, can you run these from sqlite3 (don't post the outputs here, except any errors you get) select * from ResourceInfo; select * from ResourceLink; select * from SchemaInfo; Setting status, since we're waiting on a reply 🐛🧹 ⚠️ This bug has been in NEEDSINFO status with no change for at least 15 days. Please provide the requested information, then set the bug status to REPORTED. If there is no change for at least 30 days, it will be automatically closed as RESOLVED WORKSFORME. For more information about our bug triaging procedures, please read https://community.kde.org/Guidelines_and_HOWTOs/Bug_triaging. Thank you for helping us make KDE software even better for everyone! Hi Ivan and everyone, I have performed the requested manual tests on the database using sqlite3 (version 3.51.2). Here are the results: 1. Output of .tables: ResourceEvent ResourceLink SchemaInfo ResourceInfo ResourceScoreCache 2. Output of select * from SchemaInfo;: version|2015.02.09 3. Confirmation of the SQL Error: The database appears to be physically intact. However, I can confirm the observation made by Stephan in Comment #1. My logs also show that kactivitymanagerd is attempting to execute ".tables" as a raw SQL statement, which triggers the QSqlError("1", "Unable to execute statement", "near \".\": syntax error"). 4. Functional Impact on KRunner: Due to this error, KRunner completely fails to list or search for activities. Even though activities are correctly reported via D-Bus (qdbus6), typing their names in KRunner returns no results. This effectively breaks the ability to switch activities quickly via keyboard. 5. Visual Impact on "Activity Bar" Widget: Additionally, on login, the "Activity Bar" widget is visually stuck on the first activity in the list, even if the session starts on a different one. The blue indicator does not match the actual state until I manually click on the widget, which seems to force a synchronization. It appears that the SQL syntax error prevents kactivitymanagerd from correctly serving metadata to both KRunner and the Plasma Shell widgets during the initial indexing/startup phase. $ sqlite3 ~/.local/share/kactivitymanagerd/resources/database SQLite version 3.45.1 2024-01-30 16:01:20 Enter ".help" for usage hints. sqlite> .tables ResourceEvent ResourceLink SchemaInfo ResourceInfo ResourceScoreCache sqlite> select * from ResourceInfo; <list of directories> sqlite> select * from ResourceLink; <empty> sqlite> select * from SchemaInfo; version|2015.02.09 So very similar to the other report. |
SUMMARY KRunner fails to list or search for Plasma Activities on Arch Linux. Despite the plasma-kactivitymanagerd.service being active and activities being correctly reported via D-Bus, KRunner returns no results. The service logs a persistent SQL syntax error that prevents metadata from being indexed or served to KRunner. STEPS TO REPRODUCE Create one or more Activities in System Settings. Open KRunner (Alt+Space). Type the name of an existing Activity (e.g., "Lavoro"). Observe that no Activity results are shown. Check the log file at ~/.local/share/kactivitymanagerd/resources/errors.log. OBSERVED RESULT KRunner returns no results for activities. The log file consistently shows: error: near ".": syntax error Impossibile eseguire il comando Attempts to mitigate this by setting kactivitymanagerd_plugin_sqliteEnabled=false in kactivitymanagerdrc do not stop the error from appearing, nor do they restore KRunner functionality. EXPECTED RESULT KRunner should correctly display matching Activities and allow switching between them. SOFTWARE/OS VERSIONS Operating System: Arch Linux KDE Plasma Version: 6.5.4 KDE Frameworks Version: 6.21.0 Qt Version: 6.10.1 Kernel Version: 6.18.2-arch2-1 (64-bit) Graphics Platform: Wayland ADDITIONAL INFORMATION Manual D-Bus calls (qdbus6 org.kde.ActivityManager /ActivityManager/Activities ListActivities) correctly return the Activity IDs, but ActivityName often returns empty even when defined in kactivitymanagerdrc. The syntax error near "." appears immediately upon service restart, even after deleting the ~/.local/share/kactivitymanagerd/resources/ directory. This suggests an invalid SQL query (possibly a malformed PRAGMA or table reference) generated by the daemon that is incompatible with current SQLite versions. Reinstalling kactivitymanagerd and kactivities-stats does not fix the issue.