Following Bookwyrm profile causes {nil, {:error, "Not a user"}}

Hello all,

my instance does not find this Bookwyrm account:

But it is definitely there and can be followed e.g. by Mastodon. Clicking the “Follow on Fediverse” button on this profile causes the following errors on my Akkoma instance:

[error] Could not fetch user https://tomes.tchncs.de/user/bm, {nil, {:error, "Not a user"}}

[error] Object rejected while fetching https://tomes.tchncs.de/user/bm {:transmogrifier, :error}

19:34:26.056 [error] #PID<0.1273984.0> running Pleroma.Web.Endpoint (connection #PID<0.1273983.0>, stream id 1) terminated
Server: social.techn1k.de:80 (http)
Request: GET /ostatus_subscribe?acct=https%3A//tomes.tchncs.de/user/bm
** (exit) an exception was raised:
    ** (ArgumentError) assign @followee not available in template.
Please make sure all proper assigns have been set. If this
is a child template, ensure assigns are given explicitly by
the parent template as they are not automatically forwarded.
Available assigns: [:error, :user, :token, :conn, :locale, :csp_nonce, :locales]
        (phoenix_html 3.3.3) lib/phoenix_html/engine.ex:183: Phoenix.HTML.Engine.fetch_assign!/2
        (pleroma 3.13.2-0-g050bc74) lib/pleroma/web/templates/twitter_api/remote_follow/follow_login.html.eex:5: Pleroma.Web.TwitterAPI.RemoteFollowView."follow_login.html"/1
        (phoenix_template 1.0.4) lib/phoenix/template.ex:197: Phoenix.Template.render_within_layout/4
        (phoenix_template 1.0.4) lib/phoenix/template.ex:126: Phoenix.Template.render_to_iodata/4
        (phoenix 1.7.12) lib/phoenix/controller.ex:1008: anonymous fn/5 in Phoenix.Controller.template_render_to_iodata/4
        (telemetry 1.2.1) /woodpecker/src/akkoma.dev/AkkomaGang/akkoma/deps/telemetry/src/telemetry.erl:321: :telemetry.span/3
        (phoenix 1.7.12) lib/phoenix/controller.ex:974: Phoenix.Controller.render_and_send/4
        (pleroma 3.13.2-0-g050bc74) lib/pleroma/web/twitter_api/controllers/remote_follow_controller.ex:5: Pleroma.Web.TwitterAPI.RemoteFollowController.action/2

Setup type: OTP
OS: Debian 12
PostgreSQL: 15.7
Akkoma version: 3.13.2-0-g050bc74

error is as follows:

22:20:34.227 [debug] Data is not a valid user https://tomes.tchncs.de/user/bm: {:error, "Key id does not relate to user id"}

this is because they are serving their public key id as https://tomes.tchncs.de/user/bm/#main-key - which means that post-key-resolution we have a trailing slash in the URL not present in the user ID

Thanks for your fast reply!
Is there anything I can do on my side or does this issue need to be fixed by the Bookwyrm devs?

I’ve raised it in our development channel - the solution will be to shore up the way we handle key id ownership verification

we are currently looking into the best way to handle that

1 Like

All right, then I’ll just wait and see. Thanks for taking care!

I’ve got a working implementation to fix this - required a massive overhaul of how we handle user key verification

expect this to be fixed in the next release

4 Likes