Skip to content

fix(syndicator-mastodon): thread replies to statuses on other servers - #927

Open
rmdes wants to merge 1 commit into
mainfrom
fix/syndicator-mastodon-remote-replies
Open

rmdes wants to merge 1 commit into
mainfrom
fix/syndicator-mastodon-remote-replies

Conversation

@rmdes

@rmdes rmdes commented Sep 5, 2026

Copy link
Copy Markdown
Collaborator

Fixes #926.

  • createStatus no longer throws for an in-reply-to on another server; it still sets inReplyToId for same-server replies.
  • New Mastodon#resolveRemoteStatus searches /api/v2/search?type=statuses&resolve=true, and post() threads the reply to the resolved ID. An unresolvable URL posts an unthreaded status.
  • Mock agent gains search intercepts (found / not found) and a status intercept matched on in_reply_to_id, so the tests prove threading rather than only that a status was posted.
  • Tests: reply to a resolvable remote status is threaded; reply to an unresolvable URL still posts; createStatus for an off-server reply no longer throws.

Verified locally: node --test packages/syndicator-mastodon/test/unit/*.js 40/40, eslint and prettier clean.

A reply to a status on a different server threw “Not a reply to a URL at
this target” and failed the syndication. Resolve the status through the
search API, which fetches it over ActivityPub if needed, and thread the
reply to the returned ID. A URL that can’t be resolved is posted as an
unthreaded status instead of being dropped.

Fixes #926
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Replying to a status on another Mastodon server fails the whole syndication

1 participant