Skip to content
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

Akkoma instances unable to subscribe #96

Open
mhamzahkhan opened this issue Apr 19, 2024 · 1 comment
Open

Akkoma instances unable to subscribe #96

mhamzahkhan opened this issue Apr 19, 2024 · 1 comment

Comments

@mhamzahkhan
Copy link
Contributor

I'm not sure if this is an Akkoma bug, or a bug with Activity-Relay, but I'm seeing issues with Akkoma users being unable to subscribe to my Activity-Relay instance.

I setup a test Akkoma instance to try and figure out what was going on, and found that it appears to be due to the /actor endpoint of Activity-Relay having a type of "Service". Modifying this to be type: "Application" appears to allow Akkoma instances to subscribe successfully.

Please let me know if this is an Akkoma bug, and I will open an issue with Akkoma instead. I couldn't find any guidance on what type it should be in the activitypub spec (https://www.w3.org/TR/activitypub).

Steps to Reproduce:

  • Attempt to subscribe to Activity-Relay from an Akkoma instance.
  • Observe that the subscription fails with Akkoma either outright rejecting the follow attempt with:
15:39:55.256 [error] Could not fetch user https://relay.intahnet.co.uk/actor, {nil, {:error, "Not a user"}}

15:39:55.256 [error] error: :not_found
Error while following https://relay.intahnet.co.uk/actor: :not_found

or repeatedly requesting /actor multiple times a second.

  • Inspect the Activity-Relay /actor endpoint declaration and note the type: "Service" designation.

Expected Behavior:

  • Akkoma instances should be able to successfully subscribe to Activity-Relay as it's a fork of Pleroma.

Actual Behavior:

  • Due to the /actor endpoint being categorized as type: "Service" in Activity-Relay's implementation, Akkoma instances are unable to subscribe. Either it outright rejects the follow attempt, or hammers /actor multiple times per second.

Workaround:

  • Modifying the type declaration of the /actor endpoint in Activity-Relay to type: "Application" enables successful subscription from Akkoma instances:
# modified /actor endpoint
~ $ curl -s  https://relay.intahnet.co.uk/actor | jq | grep type
  "type": "Application",
  
# Observe successful subscription from Akkoma
~ $ MIX_ENV=prod mix pleroma.relay follow https://relay.intahnet.co.uk/actor
....
16:32:11.487 [info] relay: followed instance: https://relay.intahnet.co.uk/actor; id=https://akkoma.intahnet.co.uk/activities/33a2dd78-6852-4af2-8def-f085e5d0733d
@7shironana
Copy link

This is due to a bug in Akkoma, not Relay.
I was able to follow by updating Akkoma to 3.13 or higher. Please try it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants