Login
You're viewing the techdon.dev public feed.
  • Nov 12, 2026, 9:17 PM
    @silverpill You were right, AP extensions that create new types need a completely new Object and Activity type. :D Not doing so leads to breaking assumptions made before the extensions even existed.

    One such example: Create(ActorStatus) might break timeline rendering if an assumption was made that Create activities will always be for posts (they eventually will not).
    💬 2🔄 0⭐ 0

Replies

  • Nov 12, 2026, 9:35 PM
    @phnt @silverpill

    > if an assumption was made that Create activities will always be for posts (they eventually will not)

    Create->ThingsBesidesNote is already present. There are a lot of Create activities. There's Create->Document, polls are answered with Create->Answer, etc. There's a public Grafana dashboard that has the Revolver stuff at http://pbuhwjjhrzcvrghtfqlwqlgabuzc7jnkqv4swekxjvv7pgubd7jjoiqd.onion/public-dashboards/8643a3beee524385bd0ef6a304dbbd65?orgId=0&refresh=6s and that comes from the Prometheus endpoint at FSE (https://fsebugoutzone.org/rvl/prometheus ) and the box where the apotheosis happened as well as some other nodes (which do not have public URLs), and even https://media.freespeechextremist.com/rvl/prometheus (but servers do not send activities there because it would be kind of pointless).
    create_whatever.png
    create_whatever.png
    💬 1🔄 0⭐ 0
  • Nov 12, 2026, 9:44 PM
    @p @silverpill
    >Create->ThingsBesidesNote is already present.

    I am well aware. My point is that Create despite being very clear in what it does makes things harder. Because if you write your views in a way that they fetch Create activities from the DB and preload the Object, you then have to make a list of things to exclude, because not all Objects that Create works with are what you want. You probably don't want Answer objects in your timeline view for example.

    So your query construction looks something like this:
    Activity
    |> restrict_type(activity_types)
    |> restrict_visibility()
    |> restrict_instance()
    |> restrict_object_typeX()
    |> restrict_object_typeY()
    Or alternatively you have `restrict_object_type(query, types)`

    If you have CreateAnswer, CreateNote, CreateDocument, your ingestion is more complicated and your builder is more complicated, but rendering timelines and stuff is simpler, because you can restrict by the ActivityType.
    💬 0🔄 0⭐ 0
  • Nov 13, 2026, 12:14 AM
    @phnt @silverpill

    > Because if you write your views in a way that they fetch Create activities from the DB and preload the Object, you then have to make a list of things to exclude, because not all Objects that Create works with are what you want.

    Yeah, I don't think the way Pleroma does it is optimal, but I think there'd be less DB contention if they were fetched separately, even client-side. (Individual request throughput suffers sometimes but for multiple users, you have fewer cases where someone decides to click on the hellthread and then 25s later the three-way join that includes the two biggest tables in the DB and with the visibility index and ?with_muted accounted for times out. The thing that may be faster is often trading throughput for individual reqs for more frequently releasing your req's lock on the bottlenecked resource.)

    > If you have CreateAnswer, CreateNote, CreateDocument, your ingestion is more complicated and your builder is more complicated, but rendering timelines and stuff is simpler, because you can restrict by the ActivityType.

    This would hose the only good thing ActivityPub has going for it if you mean in the protocol. If you structure your DB like that then you want to make your DB account for it: move the object type up into a column or index in the table holding the Activity instead of CreateNote->Note'ing the protocol. Pleroma doesn't *have* to put all of the objects into an objects table or all of the activities into an activities table; you could make a CreateNote table that holds the Create-Notes and split that off. "This query in this type of DB using the structure this application uses" is not something that should drive the protocol. I mean, if you want a stream of Note objects and screw whatever other objects get Create'd (and other ways to interact with objects), maybe you should walk the Notes in the objects table instead of the Create activities and then filter the ones that aren't Notes.

    Especially in this case, like, CreateNote->Answer. "You can't do that!" but someone *will*. Look at how fucked Lemmy is on follower addresses and they essentially broke "follow a board (group)" that way (and then for some reason didn't wanna fix it, or at least that is how I understand it to be). You see anything because someone will send a message to your /inbox that has that thing. There was that, I forget what it was called, "kroeg"? Active development and C# and then it went away, so the source is no longer available and there are no live servers and the kid doing it had sent a lot of activities to FSE that had weird breakages so when I imported all of them into Revolver, I kept having to stop and fix pieces: "Here's an array, why's it an array? It's not an array in any activity except *one*." (And, you know, you have to account for this kind of thing even if it's one activity because you don't want to fall over instead of just rejecting it. Like the PleromaFE crashes that happened because a timestamp was in a format that the backend didn't mind but the frontend hated. Anyway, I've been running FSE with this split-inbox where activities get POST'd to both Pleroma and Revolver and Revolver currently ignores non-public activities for obvious reasons so you see very few Create->Answers.)
    💬 0🔄 0⭐ 0
  • Nov 13, 2026, 10:36 AM

    @p @silverpill >Yeah, I don't think the way Pleroma does it is optimal, but I think there'd be less DB contention if they were fetched separately, even client-side...

    The way a lot of the processing is currently written requires the preloading, because it goes through a bunch of Object.normalize calls when doing basically anything with the data. Not ideal in all situations, but fixing it requires quite a lot of refactoring.

    This is completely my guess, but the reason why everything is built around fetching the top-level Activity instead of the Object is ActivityPub being a disfunctional protocol. If you want to do things like domain filtering for timelines, or user blocks on the DB level, you cannot rely on the Object representation to help you with that entirely.

    attributedTo is entirely useless in indicating what user made an Object, Activity Vocabulary has this helpful description of its almost-uselessness:

    Identifies one or more entities to which this object is attributed. The attributed entities might not be Actors. For instance, an object might be attributed to the completion of another activity.

    And ActivityPub says only this about that:

    When a Create activity is posted, the actor of the activity SHOULD be copied onto the object's attributedTo field.

    So your only way of figuring out what user made the Object is looking at the Activity's actor.

    >"Here's an array, why's it an array? It's not an array in any activity except one." (And, you know, you have to account for this kind of thing even if it's one activity because you don't want to fall over instead of just rejecting it.

    Yep, I've fixed a couple of those on the Pleroma AP normalization side. Some server with no source available (dead for over a year probably) sent avatars and banners as an array for some reason, which then crashed the MastoAPI search side when it came across that. I wish AP developers didn't have the paradigm of shitting out technically compliant random bullshit and have everyone else deal with normalizing it to something sane, the robustness principle fallacy.

    💬 1🔄 0⭐ 0
  • Nov 13, 2026, 10:40 AM
    @p @silverpill
    >I wish AP developers didn't have the paradigm of shitting out technically compliant random bullshit and have everyone else deal with normalizing it to something sane, the robustness principle fallacy.

    This is one of the areas where Nostr is undeniably way better designed than AP. Nostr extensions and Nostr itself has very strict JSON representation. If something doesn't conform to the specification, it is invalid. No complicated normalization and fixing things for others is needed.
    💬 0🔄 0⭐ 0
  • Nov 13, 2026, 6:00 PM

    @phnt @p

    So your only way of figuring out what user made the Object is looking at the Activity's actor.

    According to the spec... But as we all know, the spec is garbage.

    In reality, attributedTo is a very reliable indicator of ownership. Consider this common UX pattern: an user enters an URL of a post into the search bar. The server fetches the URL, but attributedTo is all there is, you can't get the corresponding Create activity.

    As far as I know, Pleroma supports this flow.

    💬 0🔄 0⭐ 0
  • 💬 1🔄 0⭐ 0
  • 💬 0🔄 0⭐ 0
  • Nov 13, 2026, 5:37 PM

    @p @phnt It is a rare one. I think I've seen this activity being produced by shoot.pub (basically Discord on ActivityPub) when it creates a new chatroom (which is a Group actor).

    💬 0🔄 0⭐ 0
  • Nov 12, 2026, 9:36 PM
    @phnt @silverpill wish it was literally "verb(object)" in the type too, so you always knew what the object: url holds without fetching it first
    💬 0🔄 0⭐ 0
  • 💬 0🔄 0⭐ 0
  • 💬 1🔄 0⭐ 0
  • Nov 12, 2026, 9:37 PM

    @phnt IMO we should ditch Add, Undo, Accept... Maybe even Delete. But not Create.

    💬 0🔄 0⭐ 0