-
Notifications
You must be signed in to change notification settings - Fork 81
Build Following
structure
#1839
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
This reverts commit e3e53b0.
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
This PR introduces the initial implementation for the Following structure as part of the Followers v2 initiative, adding support for accepting follow requests, outbox delivery, and basic actors CRUD operations for remote actors. Key changes include:
- New unit tests for Accept, Following, and Actors collections.
- Implementation of new functions (e.g. follow()) and handlers (e.g. Accept) to process follow requests.
- Updates to actor upsert, remote lookup, and related functionalities.
Reviewed Changes
Copilot reviewed 11 out of 11 changed files in this pull request and generated 1 comment.
Show a summary per file
File | Description |
---|---|
tests/includes/handler/class-test-accept.php | Adds unit tests for the Accept handler. |
tests/includes/collection/class-test-following.php | Adds comprehensive tests for following requests handling. |
tests/includes/collection/class-test-followers.php | Removes an unnecessary line in faulty followers test. |
tests/includes/collection/class-test-actors.php | Adds tests for creating, updating, deleting, and looking up remote actors. |
includes/handler/class-move.php | Minor change: adds an empty line after upserting target actor data. |
includes/handler/class-accept.php | New Accept handler implementation with validation and processing logic. |
includes/functions.php | Introduces a new follow() helper function for initiating follow requests. |
includes/collection/class-following.php | Implements the Following collection with follow() and accept() methods. |
includes/collection/class-actors.php | Updates in actor CRUD operations and lookup logic including upsert, create, update methods. |
includes/class-handler.php | Registers the new Accept handler in the global handler registration. |
.github/changelog/1839-from-description | Changelog entry for the new follow/outbox support. |
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This feels really close, nice work!
Looking good! ✨ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Let's get it in!
This PR is the next step of the Followers/Following milestone. It wraps up the Followers v2 initiative and implements the Following v1 logic.
Proposed changes:
Create
,read
,update
, anddelete
operations for remote Actor entities.Accept
handling when a follow request is accepted by the target actor.follow()
function: Helper to initiate a Follow request to a remote actor.Follow
activities are now added to the outbox.Follow
activity generation and delivery.Accept
.Notes:
Accept
is handled at this stage; other responses (e.g.Reject
) are not implemented with this PR. See HandleFollow
rejects #1865First step towards: #1036
Other information:
Testing instructions:
Changelog entry
Changelog Entry Details
Significance
Type
Message
Support for sending follow requests to remote actors is now in place, including outbox delivery and status updates—UI integration will follow later.