Repository navigation
Replace Mastodon reply threads with a single truncated post - #198
Merged
Merged
Conversation
Collaborator
Great start!
https://mastodon.social/@JustAnotherCutePet/117422982788726877 I ran this with the debugposters flag off in dev, and it looks much better without the extra threads, but the link doesn't seem to be working. |
_safe_truncate previously fell back to a word-boundary cut, which can end a truncated caption mid-sentence. Now prefer the last complete sentence (ending in . ! or ?) that fits within the limit, and fall back to the word-boundary/hard cuts as before when no sentence fits.
Threads only existed to hold caption overflow past 500 characters, but the overflow text is the pet bio, which already lives in full at the adoption link carried on the root post. Drop _post_thread, _split_reply_chunks, and MAX_REPLIES, and point readers there instead: overflow captions now end with 'More details at link 🔗', omitted when the post has no link. Publishing is now one status_post, so a mid-thread failure can no longer leave an orphaned root.
michaelgt04
force-pushed
the
drop-mastodon-threads
branch
from
October 14, 2026 00:40
378fac8 to
ce98203
Compare
binamkayastha
approved these changes
Oct 14, 2026
binamkayastha
left a comment
Collaborator
There was a problem hiding this comment.
LGTM
We think the link issues is cause rescue groups "debug" data is not in the right format
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.

The comments aren't looking great on Mastadon, so we want to get rid of the thread, truncate at the sentence level, and then reference the link.
Closes #173