A direct message answers in the form its recipient writes in
Lemmy 0.19 (most of the threadiverse) and Mbin take a private message only as a ChatMessage and refuse a direct Note. A direct message to one account elsewhere that writes to us as ChatMessages now goes out as one: to it alone, without a mention in its text, kept on the post (Post.AsChatMessage) so the served copy and an edit match. No software name decides it. Live against Lemmy 0.19: alice's answer to lemmyuser's private message and another persona's message to lemmyuser arrive (29 checks). A first message to an account that never wrote to anyone here is still a Note, which they refuse; G-0008 keeps that open for the owner. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01LsXgEaXee4GCU1hwYgPJXw
This commit is contained in:
1 parent
a85ebd30c0
commit
f38ac73615
10 files changed
+90
-17
No files matched your search
@@ -87,10 +87,21 @@ echo " private messages"
|
||||
alice_on_lm=$(lm GET "resolve_object?q=@alice_lemmy19@privapub.test" | j "print(d['person']['person']['id'])")
|
||||
lm POST private_message "{\"content\":\"a secret from Lemmy 0.19\",\"recipient_id\":$alice_on_lm}" >/dev/null
|
||||
until_true 45 'curl -s -H "$LAH" "$P/api/v1/conversations" | grep -q "a secret from Lemmy 0.19"' && ok "Lemmy 0.19's private message arrives as a DM" || ko "Lemmy 0.19's private message missing on PrivaPub"
|
||||
# (0.19 takes a private message only as a ChatMessage and answers alice's direct Note 400, G-0008; 1.0 takes a Note)
|
||||
curl -s -o /dev/null -X POST -H "$LAH" $P/api/v1/statuses -d 'status=@lemmyuser@lemmy19.test a secret from PrivaPub&visibility=direct'
|
||||
until_true 30 'lm GET "private_message/list?limit=50" | grep -q "a secret from PrivaPub"' && ok "alice's DM arrives as a Lemmy 0.19 private message" \
|
||||
|| xf "alice's DM never reaches Lemmy 0.19, which takes private messages only as ChatMessage (G-0008)"
|
||||
# lemmyuser wrote as a ChatMessage, so alice's answer goes out as one
|
||||
curl -s -o /dev/null -X POST -H "$LAH" $P/api/v1/statuses -d "status=@lemmyuser@lemmy19.test an answer from PrivaPub $run&visibility=direct"
|
||||
until_true 45 'lm GET "private_message/list?limit=50" | grep -q "an answer from PrivaPub $run"' && ok "alice's answer reaches Lemmy 0.19 as a ChatMessage" || ko "alice's answer never reached Lemmy 0.19"
|
||||
# another persona writing to lemmyuser, who writes to us as ChatMessages, does so in kind too
|
||||
LBT=$(privapub_token bob_lemmy19)
|
||||
curl -s -o /dev/null -X POST -H "Authorization: Bearer $LBT" $P/api/v1/statuses -d "status=@lemmyuser@lemmy19.test a word from bob $run&visibility=direct"
|
||||
until_true 45 'lm GET "private_message/list?limit=50" | grep -q "a word from bob $run"' && ok "bob's DM to lemmyuser goes as a ChatMessage too" || ko "bob's DM never reached Lemmy 0.19"
|
||||
# (0.19 takes a private message only as a ChatMessage and answers a direct Note 400: a first message to someone who
|
||||
# never wrote to anyone here is a Note, G-0008. 1.0 takes a Note)
|
||||
quiet="quiet$run"
|
||||
QT=$(site lemmy19.test -s -X POST "$LM/api/v3/user/register" -H 'Content-Type: application/json' \
|
||||
-d "{\"username\":\"$quiet\",\"password\":\"Lemmy-Pasture-Pass-1\",\"password_verify\":\"Lemmy-Pasture-Pass-1\",\"show_nsfw\":false}" | j "print(d['jwt'])")
|
||||
curl -s -o /dev/null -X POST -H "$LAH" $P/api/v1/statuses -d "status=@$quiet@lemmy19.test a first word from PrivaPub $run&visibility=direct"
|
||||
until_true 30 'site lemmy19.test -s "$LM/api/v3/private_message/list?limit=50" -H "Authorization: Bearer $QT" | grep -q "a first word from PrivaPub $run"' \
|
||||
&& ok "alice's first DM to someone there arrives" || xf "alice's first DM to someone there never arrives, a Note Lemmy 0.19 refuses (G-0008)"
|
||||
|
||||
echo " moderation"
|
||||
p_locked() { curl -s -H "$LAH" "$P/api/v1/statuses/$lm_cats_on_p" | j "print((d.get('privapub') or {}).get('locked'))"; }
|
||||
|
||||
@@ -110,7 +110,7 @@
|
||||
},
|
||||
{
|
||||
"id": "G-0008",
|
||||
"title": "A direct message to a Lemmy 0.19 or Mbin account never arrives: both take a private message only as a ChatMessage",
|
||||
"title": "A first direct message to a Lemmy 0.19 or Mbin account never arrives: both take a private message only as a ChatMessage",
|
||||
"match": {
|
||||
"feature": "deliver\\.direct",
|
||||
"observer": "(mbin|lemmy19)"
|
||||
@@ -120,6 +120,6 @@
|
||||
"code": "lemmy 0.19.20 crates/apub/src/protocol/objects/chat_message.rs: ChatMessageType has ChatMessage alone, so a Create{Note} to a person answers 400 (Lemmy 1.0 takes a Note); mbin 1.10.1 src/Service/ActivityPub/ActivityPubContent.php getVisibility(): a Note neither public nor to the author's followers throws 'PM: not implemented'",
|
||||
"opened": "2026-10-05",
|
||||
"status": "open",
|
||||
"note": "Neither server's actors say so, and PrivaPub never decides by a server's software name, so choosing ChatMessage for a recipient waits for the owner. Pleroma and Akkoma file a ChatMessage as a chat apart from direct messages, so sending both would show them twice. Mbin's API also never starts a conversation with an account elsewhere."
|
||||
"note": "Since 2026-10-05 a direct message to someone who writes to us as ChatMessages goes out as one (Post.AsChatMessage), so answers arrive. A first message to someone who never wrote to anyone here is still a Note: neither server's actors say what they take, and PrivaPub never decides by a server's software name, so that waits for the owner. Pleroma and Akkoma file a ChatMessage as a chat apart from direct messages, so sending both would show them twice. Mbin's API never starts a conversation with an account elsewhere."
|
||||
}
|
||||
]
|
||||
Reference in new issue
Block a user