Mastodon: UnexpectedResponseError: Delivery failed returned code 401

Created on 9 Apr 2018  路  10Comments  路  Source: tootsuite/mastodon

Hi,

I set up a new instance running 2.3.3, but whenever I try to interact with another instance, such as functional.cafe, I can only retrieve usernames and their avatars. Toots and everything else are missing, and I can't follow them correctly. The following shows up in the logs, trying to follow @[email protected] from @[email protected].

Apr 09 11:13:48 fermion bundle[28663]: 2018-04-09T09:13:48.650Z 28663 TID-gs3369rgc WARN: {"context":"Job raised exception","job":{"class":"ActivityPub::DeliveryWorker","args":["{\"@context\":[\"https://www.w3.org/ns/activitystreams\",\"https://w3id.org/security/v1\",{\"manuallyApprovesFollowers\":\"as:manuallyApprovesFollowers\",\"sensitive\":\"as:sensitive\",\"movedTo\":\"as:movedTo\",\"Hashtag\":\"as:Hashtag\",\"ostatus\":\"http://ostatus.org#\",\"atomUri\":\"ostatus:atomUri\",\"inReplyToAtomUri\":\"ostatus:inReplyToAtomUri\",\"conversation\":\"ostatus:conversation\",\"toot\":\"http://joinmastodon.org/ns#\",\"Emoji\":\"toot:Emoji\",\"focalPoint\":{\"@container\":\"@list\",\"@id\":\"toot:focalPoint\"},\"featured\":\"toot:featured\"}],\"id\":\"https://mastodon.tymoon.eu/users/shinmera#follows/2/undo\",\"type\":\"Undo\",\"actor\":\"https://mastodon.tymoon.eu/users/shinmera\",\"object\":{\"id\":\"https://mastodon.tymoon.eu/users/shinmera#follows/2\",\"type\":\"Follow\",\"actor\":\"https://mastodon.tymoon.eu/users/shinmera\",\"object\":\"https://functional.cafe/users/phoe\"},\"signature\":{\"type\":\"RsaSignature2017\",\"creator\":\"https://mastodon.tymoon.eu/users/shinmera#main-key\",\"created\":\"2018-04-09T09:08:05Z\",\"signatureValue\":\"pJE78GBIWGFcTPvwOB4knFW4Ffa8IrC3zaV1XAvs6xtPWsl4BJOu5B0XTtHgK3aMg1ymAXWp58h8jC2pIdhIS0ATXXvDYyzfsVDfXmkMfEpZpJ6+1lgzZYaZNrf7cKaDlsGL/LrN8dFSoYt6YZF6fFt6IV5V6JeHNxtBM5xV9J5ZO1SnAF98SIwO7VEaDufZtuNHuoWS8F0uEPURBkUcv624wuvm+ZaBrLAKiBJjuUqSBBYiWeD24/tZShzaqaJzB538hqaiaosboYzr/Koj4OMn1W0edTUM/OzBHixXIjgKpVK+2usLPgtA84zIkbMeeX8jDau5TgnFtgbr2ymorA==\"}}",1,"https://functional.cafe/users/phoe/inbox"],"retry":16,"queue":"push","dead":false,"jid":"b86959f4565f133011b05074","created_at":1523264885.224795,"enqueued_at":1523265228.024584,"error_message":"Delivery failed for https://functional.cafe/users/phoe/inbox: https://functional.cafe/users/phoe/inbox returned code 401","error_class":"Mastodon::UnexpectedResponseError","failed_at":1523264885.718599,"retry_count":3,"retried_at":1523265040.3041317},"jobstr":"{\"class\":\"Activ
Apr 09 11:13:48 fermion bundle[28663]: ityPub::DeliveryWorker\",\"args\":[\"{\\\"@context\\\":[\\\"https://www.w3.org/ns/activitystreams\\\",\\\"https://w3id.org/security/v1\\\",{\\\"manuallyApprovesFollowers\\\":\\\"as:manuallyApprovesFollowers\\\",\\\"sensitive\\\":\\\"as:sensitive\\\",\\\"movedTo\\\":\\\"as:movedTo\\\",\\\"Hashtag\\\":\\\"as:Hashtag\\\",\\\"ostatus\\\":\\\"http://ostatus.org#\\\",\\\"atomUri\\\":\\\"ostatus:atomUri\\\",\\\"inReplyToAtomUri\\\":\\\"ostatus:inReplyToAtomUri\\\",\\\"conversation\\\":\\\"ostatus:conversation\\\",\\\"toot\\\":\\\"http://joinmastodon.org/ns#\\\",\\\"Emoji\\\":\\\"toot:Emoji\\\",\\\"focalPoint\\\":{\\\"@container\\\":\\\"@list\\\",\\\"@id\\\":\\\"toot:focalPoint\\\"},\\\"featured\\\":\\\"toot:featured\\\"}],\\\"id\\\":\\\"https://mastodon.tymoon.eu/users/shinmera#follows/2/undo\\\",\\\"type\\\":\\\"Undo\\\",\\\"actor\\\":\\\"https://mastodon.tymoon.eu/users/shinmera\\\",\\\"object\\\":{\\\"id\\\":\\\"https://mastodon.tymoon.eu/users/shinmera#follows/2\\\",\\\"type\\\":\\\"Follow\\\",\\\"actor\\\":\\\"https://mastodon.tymoon.eu/users/shinmera\\\",\\\"object\\\":\\\"https://functional.cafe/users/phoe\\\"},\\\"signature\\\":{\\\"type\\\":\\\"RsaSignature2017\\\",\\\"creator\\\":\\\"https://mastodon.tymoon.eu/users/shinmera#main-key\\\",\\\"created\\\":\\\"2018-04-09T09:08:05Z\\\",\\\"signatureValue\\\":\\\"pJE78GBIWGFcTPvwOB4knFW4Ffa8IrC3zaV1XAvs6xtPWsl4BJOu5B0XTtHgK3aMg1ymAXWp58h8jC2pIdhIS0ATXXvDYyzfsVDfXmkMfEpZpJ6+1lgzZYaZNrf7cKaDlsGL/LrN8dFSoYt6YZF6fFt6IV5V6JeHNxtBM5xV9J5ZO1SnAF98SIwO7VEaDufZtuNHuoWS8F0uEPURBkUcv624wuvm+ZaBrLAKiBJjuUqSBBYiWeD24/tZShzaqaJzB538hqaiaosboYzr/Koj4OMn1W0edTUM/OzBHixXIjgKpVK+2usLPgtA84zIkbMeeX8jDau5TgnFtgbr2ymorA==\\\"}}\",1,\"https://functional.cafe/users/phoe/inbox\"],\"retry\":16,\"queue\":\"push\",\"dead\":false,\"jid\":\"b86959f4565f133011b05074\",\"created_at\":1523264885.224795,\"enqueued_at\":1523265228.024584,\"error_message\":\"Delivery failed for https://functional.cafe/users/phoe/inbox: https://functional.cafe/users/phoe/inbox returned code 401\",\"error_class\":\"Ma
Apr 09 11:13:48 fermion bundle[28663]: stodon::UnexpectedResponseError\",\"failed_at\":1523264885.718599,\"retry_count\":3,\"retried_at\":1523265040.3041317}"}
Apr 09 11:13:48 fermion bundle[28663]: 2018-04-09T09:13:48.651Z 28663 TID-gs3369rgc WARN: Mastodon::UnexpectedResponseError: Delivery failed for https://functional.cafe/users/phoe/inbox: https://functional.cafe/users/phoe/inbox returned code 401

This instance is set up with LOCAL_DOMAIN=tymoon.eu and WEB_DOMAIN=mastodon.tymoon.eu. I configured this before I started up mastodon for the first time or created my first user.

If there's anything else I can do to help resolve the issue, please let me know.


  • [x] I searched or browsed the repo鈥檚 other issues to ensure this is not a duplicate.
  • [x] This bug happens on a tagged release and not on master (If you're a user, don't worry about this).

Most helpful comment

Ah, that's rather confusing intended behaviour to me then.

If it's working as intended I'll close this, however. Thanks again for the help!

All 10 comments

So, obviously your instance is running. I see it. https://mastodon.tymoon.eu/about
But when I try to load in your account from m.s it doesn't come up at all. https://mastodon.tymoon.eu/@shinmera

Gonna see if I can get someone else to help trouble shoot this.

You seem to be running with a domain->subdomain mapping. Double-check that your main domain properly redirects the /.well-known/host-meta and/or webfinger route.

Looks like host-meta is OK but not the webfinger

Your .well-known/webfinger is setup incorrectly see

Yours seems to return your homepage check your webserver config again! ->
curl https://tymoon.eu/.well-known/webfinger?resource=acct:@[email protected] -L

If host-meta points to the subdomain, then it should still work afaik. Of course you can save a redirect if you just proxy the webfinger route directly...

Thanks for looking into this, I really appreciate it.

The documentation only talks about adding a host-meta redirect, which I did. I'll try adding a proxy for the webfinger route to see if that helps any.

Looks like it's working now ;D

Not quite. I can see some stuff, but I can't view people's follows or full profiles. Only pinned toots, or toots that directly interact with me seem to show up at all.

The logs occasionally show the following:

May 09 14:35:21 fermion npm[144]: ERR! 3efbae47-8842-4850-af74-0d297016b9fa Error: Missing access token

@Shinmera except for the (benign?) npm errors, this seems to be expected behavior: instances do not fetch previous toots or following/followers (except their count). You will only see toots that people on your instance have interacted with, or coming from people followed by your users.

Ah, that's rather confusing intended behaviour to me then.

If it's working as intended I'll close this, however. Thanks again for the help!

Was this page helpful?
0 / 5 - 0 ratings