Fix AP Accept: add activity id + upsert followers
All checks were successful
Build and Deploy / build-and-deploy (push) Successful in 41s
All checks were successful
Build and Deploy / build-and-deploy (push) Successful in 41s
- Accept activity now includes required 'id' field (uuid-based) - Updated shared submodule: add_follower upserts to prevent IntegrityError Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -7,6 +7,7 @@ from __future__ import annotations
|
||||
import json
|
||||
import logging
|
||||
import os
|
||||
import uuid
|
||||
|
||||
import httpx
|
||||
from quart import Blueprint, request, abort, Response, g, render_template
|
||||
@@ -52,8 +53,10 @@ async def _send_accept(
|
||||
username = actor.preferred_username
|
||||
actor_url = f"https://{domain}/users/{username}"
|
||||
|
||||
accept_id = f"{actor_url}/activities/{uuid.uuid4()}"
|
||||
accept = {
|
||||
"@context": "https://www.w3.org/ns/activitystreams",
|
||||
"id": accept_id,
|
||||
"type": "Accept",
|
||||
"actor": actor_url,
|
||||
"object": follow_activity,
|
||||
|
||||
Reference in New Issue
Block a user