-
Notifications
You must be signed in to change notification settings - Fork 78
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
Undo activity without an ID on the object activity #384
Comments
I think the spec (or recommendations) should just require IDs, and not allow unfollows by actor/shape. |
|
The problem occurs when the EDIT: it happens for the following "stateful" activities:
|
@trwnh I think you're trying to suggest that there was a recent decision to make the elements of |
I meant with the triage of #381 it was decided to make the implication explicit, at least within the primer. Not necessarily that a new decision was made, but a decision was made at some point, and that decision was clarified during the issue triage yesterday. Although I have to raise another point of contention: when was it decided that Taking |
@trwnh Idempotency is generally a desirable property in a distributed system. The connection between servers could be flaky and the sender may see a request timeout and retry activity delivery not knowing that recipient already processed it. I think for multiple shares it would be better to add a property specifying the total number of shares to |
@silverpill a primary characteristic of Tumblr style reblogs is that they continue to exist after reblogging again, each with their own timestamp and permalink. In IndieWeb this would be possible due to how Idempotency generally happens as a property of having some idempotency key, in this case the |
I think the best resolution for this problem is guidance within the Primer for referring to activities. We can apply the Postel principle and say that for best interoperability, the publisher should include the ID, and the consumer should accept activities without IDs if they can identify them uniquely another way. I'll add this section to the Primer, and we can consider from there. https://www.w3.org/wiki/ActivityPub/Primer/Referring_to_activities We agreed during triage that it does make sense for consumers to make an effort to identify activities with no id if other attributes uniquely identify them. We had some disagreement about whether consumers should identify activities with an id property that hasn't been seen before, possibly because the publisher did not store the id it used originally. So, the guideline there is somewhat weaker. |
@evanp From Primer:
Any examples of such systems? In my experience, the majority of AP implementations have no problem with including referred activity ID in Undo, Accept and Reject. Yes, it is possible to identify referred activities by shape, but I think this should not be a recommendation. In particular, this guideline should not be applied to Undo, Accept and Reject:
Because that would shift the burden from a few buggy implementations to everyone else. Postel principle is not universal. It should be used carefully as its application leads to protocol decay: https://datatracker.ietf.org/doc/html/draft-thomson-postel-was-wrong-00 |
I suggest the following changes to Primer:
|
@silverpill I think Misskey and Mastodon have come up as examples that don't keep persistent activity IDs for some activities. In terms of the guidelines, they're helpful tips for what developers should do to maximize interoperability. They're not normative requirements; there's no MUST possible. If you want to maximize interoperability, the Postel principle is a good one to follow. I agree that publishers should include IDs for maximum interop, but also that consumers should try to handle ID-less activities. If both sides do some extra work, we can avoid interop failures. Activity Streams 2.0 does not require an ID for pretty much anything; ActivityPub doesn't require it for referenced activities. In the absence of an ID, the guidelines hold. |
@trwnh I'm moving the conversation about multiple Announce activities to another issue. |
@silverpill another good example might be for C2S! A client that wants to let a user undo a follow needs to first find the object in |
@evanp I have data on Mastodon and it uses the same activity ID in Perhaps these implementations didn't store activity IDs in the past? I don't know.
What about "should store IDs of Like, Follow and Announce activities"? The Primer is authoritative and developers will follow its recommendations. Maximizing interoperability at all costs would mean accounting for quirks of 50+ different implementations, this is not sustainable. Reduction of technical debt and interop improvements should go hand in hand.
Quite possible. There might be cases where identification by shape makes the most sense. But for Undo/Accept/Reject in S2S context this is not necessary because using IDs is a de-facto standard (even if the spec doesn't require them). |
This issue has been mentioned on SocialHub. There might be relevant details there: https://socialhub.activitypub.rocks/t/follow-accept-object-identifiers/3851/9 |
This issue has been mentioned on SocialHub. There might be relevant details there: https://socialhub.activitypub.rocks/t/an-fep-for-follow-accept-mechanics/4266/5 |
I think that's a fair resolutions. I changed it from "should" to "may". It probably also makes sense in general for us to avoid SHOULD, MUST, MAY, and other RFC 2119 terms in the Primer, since it is helpful guidance, not normative specification. I'm going to leave this as pending closure until we hear back from @silverpill . |
@evanp Thank you for making this change. Also +1 for avoiding RFC-2119 key words. |
I might suggest a couple of small revisions to more clearly and fully avoid RFC-2119 keywords...
(I know, lowercase |
i'll assume that @silverpill is ok with even less normative language of "can", so since objections are resolved, ill close this issue. |
Is it possible to process an Undo activity without an ID on the object activity? For example, to undo a
Like
activity:If the
likes
collection of the object is unique byactor
, it is possible to execute the side effect of this activity without needing the id of theLike
.Similarly, for undoing a
Follow
activity:If the
followers
collection of the actor that is being unfollowed is unique byid
, then it should possible to execute the side effect of removing the Undo activity's actor from thefollowers
collection without needed the exact id of theFollow
activity.The text was updated successfully, but these errors were encountered: