Use full post body in AP notes, not just excerpt
All checks were successful
Build and Deploy / build-and-deploy (push) Successful in 54s

Federated content has no character limit — use the complete plaintext
body so followers see the full post in their timeline.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
giles
2026-02-22 09:40:19 +00:00
parent 4c44fc64c5
commit 36c33d9ce2

View File

@@ -1006,14 +1006,10 @@ def _build_ap_post_data(post, post_url: str, tag_objs: list) -> dict:
if post.title:
parts.append(f"<p>{html_escape(post.title)}</p>")
excerpt = post.custom_excerpt or post.excerpt or ""
if not excerpt and post.plaintext:
excerpt = post.plaintext[:500]
if len(post.plaintext) > 500:
excerpt = excerpt.rsplit(" ", 1)[0] + "\u2026"
body = post.plaintext or post.custom_excerpt or post.excerpt or ""
if excerpt:
for para in excerpt.split("\n\n"):
if body:
for para in body.split("\n\n"):
para = para.strip()
if para:
parts.append(f"<p>{html_escape(para)}</p>")