Profanity: Wrong message display

Created on 25 Nov 2019  Â·  12Comments  Â·  Source: profanity-im/profanity

I received MUC messages which were displayed wrong. The date was also "injected" in the message.

Expected Behavior

The date should not be "injected" in the message.

Current Behavior

2019-11-25-181008_scrot

Context

grep Kter profanity.log.99 
25/11/2019 17:38:44: xmpp: DBG: RECV: <message lang="en" to="REMOVED/rF9sqBAM" type="groupchat" from="[email protected]/Licaon_Kter [web]"><inactive xmlns="http://jabber.org/protocol/chatstates"/><no-store xmlns="urn:xmpp:hints"/><no-permanent-store xmlns="urn:xmpp:hints"/></message>
25/11/2019 17:38:44: prof: ERR: Message received without body for room: [email protected]/Licaon_Kter [web]
25/11/2019 17:44:08: xmpp: DBG: RECV: <presence lang="en" type="unavailable" to="REMOVED/rF9sqBAM" from="[email protected]/Licaon_Kter [web]"><x xmlns="http://jabber.org/protocol/muc#user"><item role="none" affiliation="none"/></x></presence>
25/11/2019 17:44:08: prof: DBG: Unavailable presence handler fired for [email protected]/Licaon_Kter [web]
25/11/2019 17:44:08: prof: DBG: Room presence received from [email protected]/Licaon_Kter [web]
25/11/2019 18:02:59: xmpp: DBG: RECV: <message id="812fe59f-55d4-4e26-a749-2e084ec9cbef" lang="en" to="REMOVED/rF9sqBAM" type="groupchat" from="[email protected]/Licaon_Kter"><origin-id id="812fe59f-55d4-4e26-a749-2e084ec9cbef" xmlns="urn:xmpp:sid:0"/><body>Martin: i think the massage comes from /me saying &quot;buy coins from Martin@domain&quot;</body><stanza-id id="2019-11-25-45c772389fbcdf1d" by="[email protected]" xmlns="urn:xmpp:sid:0"/></message>
25/11/2019 18:02:59: prof: DBG: Attempting notification: Licaon_Kter in operators (win 20)
25/11/2019 18:03:15: xmpp: DBG: RECV: <message id="f54dcc1e-903d-40f5-a905-80c0813f5105" lang="en" to="REMOVED/rF9sqBAM" type="groupchat" from="[email protected]/Licaon_Kter"><origin-id id="f54dcc1e-903d-40f5-a905-80c0813f5105" xmlns="urn:xmpp:sid:0"/><body>Martin: so...you ban me or Martin@domain ?</body><stanza-id id="2019-11-25-166194fa31362cf0" by="[email protected]" xmlns="urn:xmpp:sid:0"/></message>
25/11/2019 18:03:15: prof: DBG: Attempting notification: Licaon_Kter in operators (win 20)

Environment

Debian Bullseye (Testing)

profanity -v
Profanity, version 0.7.1dev.master.f0a719d1
Copyright (C) 2012 - 2019 James Booth boothj5web@gmail.com.
Copyright (C) 2019 Michael Vetter jubalh@iodoru.org.
License GPLv3+: GNU GPL version 3 or later https://www.gnu.org/licenses/gpl.html

This is free software; you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.

Build information:
XMPP library: libstrophe
Desktop notification support: Enabled
OTR support: Enabled (libotr 4.1.1)
PGP support: Enabled (libgpgme 1.13.1-unknown)
OMEMO support: Enabled
C plugins: Enabled
Python plugins: Enabled (2.7.17)
GTK icons: Enabled

bug

Most helpful comment

Maybe :/ I don't get what's exactly going on here. Still guessing that utf8proc might help.

BTW. not just the highlighting is weird. the text also is :D

All 12 comments

Licaon_Kter was using conversations.

Ignore the [web] ones as that client is not online and not in that room.

I don't see what's happening here. Can somebody point out what exactly causes this?

showprofstrangemessage

/xc2 and /xa0 ?

@mdosch please paste later the specific color setting you used, that I don't have.

roommention=yellow
roommention.term=orange1

Probably related to https://github.com/profanity-im/profanity/issues/1220.
Maybe we need to use utf8proc to normalize displayed strings.

Another example
2020-02-07-114131_scrot

07/02/2020 11:39:27: xmpp: DBG: RECV: 
<message id="4b504154-f77c-43ac-9777-c592311251ca" lang="en" to="[email protected]/saWTE9GK" type="groupchat" from="[email protected]/Alacer">
<archived id="1581071967519266" by="[email protected]" xmlns="urn:xmpp:mam:tmp"/>
<stanza-id id="1581071967519266" by="[email protected]" xmlns="urn:xmpp:sid:0"/>
<origin-id id="4b504154-f77c-43ac-9777-c592311251ca" xmlns="urn:xmpp:sid:0"/>
<body>&gt; Signal, Threema, Matrix and Telegram everywhere. Seems like XMPP really needs some marketing…
Martin: 100% agreed.... Even Technically what innnovative tech these Apps/App Decelopers are using is not Envisined as IM Solution as Opposed to XMPP.... off course One can always argue ...
</body>
</message>

I got weird highlighting in a message today:
2020-02-10-133837_222x25_scrot

(optmzr is what should have been highlighted)

In this case it could be the letter ö that is messing things up, maybe?

Edit:
Here's a way to reproduce:
2020-02-10-134243_231x42_scrot

Just write a bunch of ö before the name and everything is offset :)

Maybe :/ I don't get what's exactly going on here. Still guessing that utf8proc might help.

BTW. not just the highlighting is weird. the text also is :D

BTW. not just the highlighting is weird. the text also is :D

We're battle testing Profanity's UTF-8 support daily :sunglasses:

showopt

Now that is confusing. Maybe the locale matters? Maybe the ncurses version/terminal?

I'm using:
Profanity: v0.8.1
ncurses: 6.1_p20190609
Theme: (solarized)
2020-02-10-144513_185x88_scrot

Was this page helpful?
0 / 5 - 0 ratings

Related issues

PMaynard picture PMaynard  Â·  3Comments

boothj5 picture boothj5  Â·  8Comments

wstrm picture wstrm  Â·  3Comments

moppman picture moppman  Â·  3Comments

boothj5 picture boothj5  Â·  4Comments