~aereaux


#32 Unable to install using pipx on a recent Arch Linux system with python 3.12 21 days ago

Comment by ~aereaux on ~nicoco/slidge-whatsapp

That's really weird, it works on my machine (when pipx installing :-/). Any idea what I could do to get it closer to what the CI does to reproduce?

#32 Unable to install using pipx on a recent Arch Linux system with python 3.12 30 days ago

Comment by ~aereaux on ~nicoco/slidge-whatsapp

Yes, I was able to install after installing go, it mostly just takes a little longer. Thanks for looking into this!

#32 Unable to install using pipx on a recent Arch Linux system with python 3.12 a month ago

Ticket created by ~aereaux on ~nicoco/slidge-whatsapp

I just upgraded my arch linux system to python 3.12 and now I am unable to (re-)install slidge-whatsapp using pipx: https://upload.jmad.org/upload/59bf6f2e-e550-4706-b81e-91ae7b5b46d2/cmd_2024-04-27_08.13.16_pip_errors.log

I think this is because the CI only builds the wheel for python 3.11. I haven't tested it because I don't have access to the CI but this might fix it: https://upload.jmad.org/upload/27985ba8-67a5-4662-94d0-7d1a322fc3b5/0001-Add-build-for-python-3.12.patch

#27 Poll support 2 months ago

Comment by ~aereaux on ~nicoco/slidge-whatsapp

It looks like polls are currently silently dropped (unless there's some sort of misconfiguration on my side). It could be useful to at least have a message saying to check the app in the meantime

#29 Constant disconnects with new Cheogram version 3 months ago

Ticket created by ~aereaux on ~nicoco/slidge-whatsapp

I discussed this more in the slidge xmpp muc, but I think I found the problem and solution.

After upgrading to cheogram version 2.13.4-1+free, I'm no longer able to join slidge-whatsapp chats/mucs. This seems to be because cheogram now sends iq:register stanzas to each muc:

DEBUG:slixmpp.xmlstream.xmlstream:RECV: <iq to="#chat@whats.jmad.org" id="bDc-eBifZSDb" type="set" from="me" xml:lang="en"><query xmlns="jabber:iq:register"><x xmlns="jabber:x:data" type="submit"><field var="FORM_TYPE"><value>http://jabber.org/protocol/muc#register</value></field><field var="muc#register_roomnick"><value>my name</value></field></x></query></iq>

As far as I can tell this triggers a bunch of these, possibly overwhelming the whatsapp connection:

DEBUG:slidge.util.db:Getting user me
DEBUG:slidge.util.db:Getting user me
DEBUG:slidge.core.gateway.registration:Modify user: <User me>
DEBUG:slidge.util.db:Adding user me/resource
DEBUG:slidge.util.sql:User has already been added.
DEBUG:slidge.util.db:Store: <shelve.DbfilenameShelf object at 0x7fd70939cd90>
DEBUG:slidge.core.gateway.registration:Modify user: <User me>
DEBUG:slidge.util.db:Adding user me/resource
DEBUG:slidge.util.sql:User has already been added.
DEBUG:slidge.util.db:Store: <shelve.DbfilenameShelf object at 0x7fd70939cd90>
DEBUG:slixmpp.xmlstream.xmlstream:Event triggered: user_modify
DEBUG:slixmpp.xmlstream.xmlstream:Event triggered: user_modify

Based on my understanding of the code, I think this is caused by this overly-broad stanza path match here: https://git.sr.ht/~nicoco/slidge/tree/master/item/slidge/slixfix/xep_0077/register.py#L80 . I commented out the handler lines and it seems to be working fine now.

This patch might be a proper fix:

From def406055f6dfcbe78dde74723ea82474539ea46 Mon Sep 17 00:00:00 2001
From: Aidan Epstein <aidan@jmad.org>
Date: Wed, 28 Feb 2024 16:30:44 -0800
Subject: [PATCH] Make `iq:register`s only respond to the bare component jid

instead of to mucs as well.
---
 slidge/slixfix/xep_0077/register.py | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/slidge/slixfix/xep_0077/register.py b/slidge/slixfix/xep_0077/register.py
index c3d8beb..e6e9e4f 100644
--- a/slidge/slixfix/xep_0077/register.py
+++ b/slidge/slixfix/xep_0077/register.py
@@ -80,7 +80,7 @@ class XEP_0077(BasePlugin):
             self.xmpp.register_handler(
                 CoroutineCallback(
                     "registration",
-                    StanzaPath("/iq/register"),
+                    StanzaPath(f"/iq/register@to={self.xmpp.boundjid.bare}"),
                     self._handle_registration,
                 )
             )
-- 
2.44.0

Let me know if I got anything wrong here, I have a lot of debug logs and the ability to test more.

#190 Component tried to send from address &lt;&lt; 3 months ago

Comment by ~aereaux on ~nicoco/slidge

It might be this that's triggering the problem:

Feb 28 02:49:00 hathor python[1707022]: DEBUG:slidge.core.gateway.base:SEND: <iq type="get" to="<me>" id="8b7365108d1e4bd98175fddce7f01560"><pubsub xmlns="http://jabber.org/protocol/pubsub"><items node="urn:xmpp:avatar:data"><item id="f1b05225baab3513bafb43c5627f61bccc3cc85b" /></items></pubsub></iq>

#190 Component tried to send from address &lt;&lt; 3 months ago

Comment by ~aereaux on ~nicoco/slidge

Yeah, I was looking through the prosody debug logs but didn't see any stanzas without a from. I'll debug this more when I have time, and I'll try the slidge-whatsapp logs next.

#190 Component tried to send from address &lt;&lt; 3 months ago

Comment by ~aereaux on ~nicoco/slidge

It looks like adding validate_from_addresses = false to my prosody config works around this issue: https://hg.prosody.im/trunk/rev/5f182bccf33f . Looks like that is a bug in slidge with the from address then.

#190 Component tried to send from address &lt;&lt; 3 months ago

Ticket created by ~aereaux on ~nicoco/slidge

I'm getting this error in prosody (trunk) with slidcord and slidge-whatsapp:

Feb 24 07:28:14 hathor prosody[1616285]: mod_component: Disconnecting component, <stream:error> is: <stream:error><invalid-from xmlns='urn:ietf:params:xml:ns:xmpp-streams'/><text xmlns='urn:ietf:params:xml:ns:xmpp-streams'>Component tried to send from address &lt;&lt; [missing &apos;from&apos; attribute] &gt;&gt; which is not in domain &lt;whats.jmad.org&gt;</text></stream:error>

#26 Missing message and "Error decrypting message" 4 months ago

Ticket created by ~aereaux on ~nicoco/slidge-whatsapp

I missed a message and some reactions on a whatsapp group earlier today it looks like. This looks like a relevant error message around the right time:

Feb 14 19:22:12 <machine> python[1342807]: WARNING:slidge_whatsapp.gateway:Error decrypting message from <number>:<shortnumber>@s.whatsapp.net in <longnumber>@g.us: failed to decrypt group message: no sender key for <number>:<shortnumber> in <longnumber>@g.us

Let me know if there's any other debugging info I can provide