Cannot mention (or send DMs to) users with dot or other "uncommon" chars in name #1011
Labels
No labels
approved, awaiting change
broken setup
bug
cannot reproduce
configuration
documentation
duplicate
enhancement
extremely low priority
feature request
Fix it yourself
help wanted
invalid
mastodon_api
needs change/feedback
needs docs
needs tests
not a bug
not our bug
planned
pleroma_api
privacy
question
static_fe
triage
wontfix
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
AkkomaGang/akkoma#1011
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Your setup
From source
Version
(current develop)
d96c6f438dPostgreSQL version
17
What is wrong?
Sending a DM with a text like
will not actually get processed as a mention of the remote user and thus noöne except the author themselves is actually receiving the message.
That’s because Pleroma’s
Linkifylibrary which we use to auto-insert clickable links, extract hashtags and extract mentions uses this, kinda restricitive regex for matching mentions:~r/^@(?<user>[a-zA-Z\d_-]+)(@(?<host>[^@]+))?$/(one can test what it detects by changing the passed
mention_handlerto print out what was found)This affects the Bridgy setup bot
@bsky.brid.gy@bsky.brid.gywhich is how I got made aware of this (see: https://github.com/snarfed/bridgy-fed/issues/374#issuecomment-3422614199 )So far so understandable. The really weird thing here is, back when testing the initial Bridgy interop after fixing signatures etc, I did successfully exchange DMs with the bot.
At this point the formatting was already kinda iffy, rendering the handle as an at-symbol followed by a link, but it still produced a
mentionin the API and thus reached the bot.I tried to bisect this but both
522a168af6(what the HTTPSig PR was originally starting from) and5987dd43d4(after the PR got merged) already fail the “with dot” test:Elixir tests intended to bisect this
Which might suggest akkoma-fe somehow used to send explicit addressing for DMs? But I don’t remember it doing that nor any FE change related to addressing in the last year. Am confused how this ever worked.
Severity
I can manage
Have you searched for this issue?
Mystery solved. When initially enabling bridging (via a follow req) the bridge bot sends out a DM and all my test DMs to the bot were replies to this. When replying like this the bot will be addressed and mentioned even without linkify detecting any inline mentions.
Sending non-reply DMs was indeed always broken