Can't re-follow an unfollowed relay
When I do a sequence of:
mix pleroma.relay follow https://relay.somewhere/actor
mix pleroma.relay list
mix pleroma.relay unfollow https://relay.somewhere/actor
mix pleroma.relay list
mix pleroma.relay follow https://relay.somewhere/actor
The second follow doesn't reach the relay and as a result, I'm not subscribed to it. The second list still shows the relay, so it is likely the unfollow that is failing.
I've confirmed with clean test instances of Pleroma (on develop) and the relay that the first follow and unfollow reach the relay. The second follow doesn't. The relay no longer shows the Pleroma instance in its relay.manage list
. If I then delete the relay user in the AdminFE as a workaround, the mix pleroma.relay list
no longer shows the relay and the next follow is successful.
Side note: In my live instance (on stable) this workaround doesn't work for a real relay, because when deleting this (remote) relay user, delete_user_activities tries to Unannounce all Announces made by the relay and if one fails, the user deletion fails. In my case, something is botched somewhere such that at least one Object.normalize on an Announce Activity yields a nil object, which is not handled gracefully; but that's likely just a local problem.