activitypub
activitypub copied to clipboard
Spec contradicts itself when describing what the `liked` collection should contain
Thanks to @tuxether for being inquisitive which led me to this.
§5.5 Liked states:
Every actor MAY have a liked collection. This is a list of every object from all of the actor's Like activities, added as a side effect.
§5.7 Likes has a Note box that says:
liked: Specifically a property of actors. This is a collection of Like activities performed by the actor
(Emphasis is not mine)
So is the liked
collection expected to contain an actor's Like
activities, or all the actor's Object
s referred to in their Like
activities?
While being symmetrical (likes
and liked
being collections of Like
activities) would be nice, it's only mentioned in the Note box. The definitive section on liked
would make it asymmetrical (Like
activities vs Object
s)
Note that the implementation report at test.activitypub.rocks says:
Adds the object to the actor's Liked Collection.
which implies that §5.7's Note box is incorrect.
It does seem like 'liked' would make most sense to be the objects that were liked, not the like activities. aka 5.5 is a better definition, and 5.7 should be changed.
'likes' might also be a thing some servers want to provide, but that's different than addressing this conflict in the spec.
When I ported the original ActivityPub Test Suite to Python, I saw that the original C2S "like" test was searching for a Note in the "liked" collection, not a Like activity. Given the test suite was written by one of the specification authors, it's a hint about the intended representation. It would be nice to have an official resolution of this ambiguity.
This issue has been mentioned on SocialHub. There might be relevant details there:
https://socialhub.activitypub.rocks/t/like-activity/2925/16
As per this and #349 , the text of the non-normative note is incorrect. I've created an erratum which says:
In section 5.7, in the non-normative note, the description of the "liked" collection should read "liked: Specifically a property of actors. This is a collection of objects liked by the actor, added to the collection as a side effect of delivery to the outbox."
I'm going to mark this issue as needs errata, and needs group input. We can discuss at the next CG meeting, and if approved, we'll add it to errata and the editor's draft.
https://www.w3.org/wiki/ActivityPub_errata/Proposed