Event Calendar causes plasmashell crash if an event summary contains emojis
After adding a Google calendar, clicking Event Calendar causes plasmashell to freeze and then crash. Problem does not occur with no calendar added. Reproduced on multiple installs of Antergos with both Plasma 5.8 and Plasma 5.9.
So it opens fine when you're not logged into google calendar? It's only when the events are loaded that it crashes? How many calendars do you have? Are they all shown?
Yep. That's correct. I only have the one calendar active and shown.
Any errors in ~/.xsession-errors?
Have just re-added the calendar and seems to be working ok now. Apologies. I'll update if the problem recurs.
How is it installed on antergos? Through the "download new widgets" GUI or via a package manager that downloads from git master?
Ah Antergos is just AUR right? So the package manager installs to /usr/share/plasma/plasmoids/, but might be overloaded if you also installed an older version via the GUI to ~/.local/share/plasma/plasmoids/.
That's right. Antergos is basically little more than a GUI Arch installer. I think you might be right on the cause. Thank you so much for your help :-)
Has recurred after trying to update to git version 0.40. Could this be to do with unpurged previous configs? How can I clear them? Thank you. Also, nothing in ~/.xsession-errors
Do you have Qt 5.8.0?
Does the tag tiledmenu-39 work still?
Er eventcalendar-39 **
Reason I ask is because slytry on https://store.kde.org/p/998901 reported this crash too with v30 and v40 on Antergos too. However it worked for you so I wasn't sure.
slytry: Crashes on plasma 5.9. Would you update please?
Antergos, KDE 5.9.0, Qt 5.8.0, v. 30 Event Calendar.
But now I update and check if it keeps crashing. Even with v.40 Plasma keeps crashing, exactly when the events of the calendar are showed
I am on Qt 5.8.0. How do I try the tag?
git checkout eventcalendar-39 then sh ./reinstall. You can confirm it installed correctly by checking the version in the config.
Ok, I'll try now...
git checkout eventcalendar-39 results in
fatal: Not a git repository (or any of the parent directories): .git
Ah woops, you'll need to this first:
https://github.com/Zren/plasma-applets/tree/master/org.kde.plasma.eventcalendar#b-install-via-github
git clone https://github.com/Zren/plasma-applets.git
cd plasma-applets/org.kde.plasma.eventcalendar
git checkout eventcalendar-39
sh ./reinstall
Have followed the instructions and v39 is reinstalled. Problem remains :-(
As long as the Google account is logged out, there are no crashes. It's still better than the default clock; would be really useful if it worked properly, though!
Not sure if arch fixed something, or if my virtual machine environment isn't a perfect reproduction. I installed Antergos in virtualbox.


Still no improvement here, and the version of Arch/Antergos I'm using is an exact match.
Interesting... now seems to work with the contacts and local holidays calendars, but dies if I add my main calendar...
If you get the time, could you turn on debugging output (new) in the new v41 (bottom of the general tab). Then login to gmail, select a calendar that works and enable it. Reload the events. Then turn on the bad calendar.
Then email me the logs (logs will contain your access token). My gmail is zrenfire.
It seems like it's your calendar event data that's foobaring it. Hopefully I can reproduce it with the event data.
Hum, maybe it's the unicode/emoji characters? On my version of KDE Neon, I tried installing the Noto emoji character set I think. And the emojis in your events have blank spaces.

where as in my antergos vm, it looks like the characters are missing.

Try changing the event names with those in the current visible month (Jan 29 - Mar 11). If it's not that then it's something else.
Hi Chris
Thanks! :-) That appears to have fixed it! Removed the emoji characters and now the calendar works as expected.
Thank you again!
Matt
On 13 Feb 2017, at 23:41, Chris Holland [email protected] wrote:
Hum, maybe it's the unicode/emoji characters? On my version of KDE Neon, I tried installing the Noto emoji character set I think. And the emojis in your events have blank spaces.
where as in my antergos vm, it looks like the characters are missing.
Try changing the event names with those in the current visible month. If it's not that then it's something else.
— You are receiving this because you modified the open/close state. Reply to this email directly, view it on GitHub, or mute the thread.
User in the opendesktop.org comments had the same issue. https://store.kde.org/p/998901/

So this was a change to either:
- coloured Emoji rendering
- The PlasmaComponents.Label which extends Text
- https://github.com/KDE/plasma-framework/blob/master/src/declarativeimports/plasmacomponents/qml/Label.qml
- https://github.com/KDE/plasma-framework/commits/master/src/declarativeimports/plasmacomponents/qml/Label.qml
- Check if isMobile to use Qt.TextRendering instead of native rendering
- The other is a missing import fix probably based on an extension of the previous commit.
- Qt Text
Or.... I'm using Text not Label which means it's not using native rendering. Innnnteresting.
What do you mean with innnnteresting?
As in I can probably change it to use a Label and/or use set it to native rendering in the next version and get you guys to test if it works without affecting other users. I'm not 100% if that will fix it though, it's just a path forward.
If it doesn't I'll need to look into how coloured emoji's were first implemented, the bug tracker for emoji related bug, if they were ever tested in QML / Plasma's QML widgets, and as a last hope, skim through Qt for any related changes.
The thing is though, that the Antergos setup in my VM is showing them as missing characters, so I still don't know how to reproduce the crash.
Ok, hope you can find a way to get it. I'm missing the plasmoid too much! Thank you.
Hmmm. Do any of you have window title labels in the taskbar? If so, does visiting the following url cause plasmashell to crash? It has 🤑 in the title, so since that tab is selected in your browser window, the title will be the window title, shown in the label in the taskbar.
https://en.wikipedia.org/w/index.php?title=%F0%9F%A4%91&redirect=no
It seems that emojis show up fine in the taskmanager label in kde neon for me, even though they doesn't show up in eventcalender. Here's how taskmanager is doing it:
https://github.com/KDE/plasma-desktop/blob/master/applets/taskmanager/package/contents/ui/Task.qml#L471
It ensures textFormat: Text.PlainText and uses Label. I think this is the default value though.
If we look at text: model.display, it's the property of a cpp model libtaskmanager. I can't find anything interesting in taskmodel.cpp though that cleans up the title. The fact that it's a C++ string, versus a json decoded javascript string in eventcalendar might be the key.
I looked into filtering all emojis with regex, but it doesn't seem to work. Using \u0F911 didn't work, nor did \u{0F911} which is Ruby syntax, but pasting 🤑 into the regex did. I don't want to try making a blacklist of characters at this rate. I might try making a whitelist, but I might miss a foreign character set and create another bug.
Hmmm, I just noticed that it shows up as %F0%9F%A4%91 when url encoded.