fediverse-devnet / feditest

A testing framework for distributed, heterogeneous systems communicating with complex protocols, such as the Fediverse
https://feditest.org/
MIT License
33 stars 6 forks source link

Question: Why are make_create_note, etc., on FediverseNode instead of ActivityPubNode? #286

Closed steve-bate closed 1 week ago

steve-bate commented 2 months ago

These seem to be ActivityPubNode operations:

jernst commented 2 months ago

The idea was the only put into ActivityPubNode behaviors that are clearly specified in the ActivityPub spec, but put all others into grab-bag FediverseNode. That's in order to avoid that somebody who has implemented ActivityPub, but not for the purpose of interoperating with Mastodon etc., gets up and says "but the spec doesn't require that".

That doesn't mean I got it right which is which. Lots of them -- the ones we have, and more to come -- are judgment calls imho.

steve-bate commented 2 months ago

The idea was the only put into ActivityPubNode behaviors that are clearly specified in the ActivityPub spec ...

I thought it might be something like that, but the operations I listed are defined in the ActivityPub spec, so I wasn't sure. For example,

def make_a_follow_b(self, a_uri_here: str, b_uri_there: str, node_there: ActivityPubNode) -> None:

is explicitly dependent on an ActivityPubNode. I think it would be better to move these "interface" methods into the ActivityPubNode. It's not clear to me that we need a FediverseNode type at this point.

jernst commented 2 months ago

Let's deal with this after #273

jernst commented 1 week ago

This is now a "system" test functionality rather than a "protocol" test functionality, so it's in the right place.