Can't report a specific post
Environment
- Installation type (OTP or From Source): Source
- Pleroma version (could be found in the "Version" tab of settings in Pleroma-FE): 2.2.0
- Elixir version (
elixir -v
for from source installations, N/A for OTP): 1.10.4 - Operating system: Ubuntu 20.04
- PostgreSQL version (
psql -V
): 12.4
Bug description
POST /api/v1/reports
with this body:
{"account_id":"A0vjOSORWlZr8xLEvo","status_ids":["A14BpwngvxvbFXjAga"],"comment":"","forward":false}
Results in a 500 error response:
{"errors":{"detail":"Internal server error"}}
It doesn't happen on all posts, only some. This is the post in question: https://gleasonator.com/notice/A14BpwngvxvbFXjAga
Here's the error on the BE:
Nov 15 01:24:07 gleasonator mix[844098]: Server: gleasonator.com:80 (http)
Nov 15 01:24:07 gleasonator mix[844098]: Request: POST /api/v1/reports
Nov 15 01:24:07 gleasonator mix[844098]: ** (exit) an exception was raised:
Nov 15 01:24:07 gleasonator mix[844098]: ** (Postgrex.Error) ERROR 54000 (program_limit_exceeded) index row size 3552 exceeds btree version 4 maximum 2704 for index "activities_create_objects_index"
Nov 15 01:24:07 gleasonator mix[844098]: table: activities
Nov 15 01:24:07 gleasonator mix[844098]: constraint: activities_create_objects_index
Nov 15 01:24:07 gleasonator mix[844098]: hint: Values larger than 1/3 of a buffer page cannot be indexed.
Nov 15 01:24:07 gleasonator mix[844098]: Consider a function index of an MD5 hash of the value, or use full text indexing.
Nov 15 01:24:07 gleasonator mix[844098]: Index row references tuple (956823,8) in relation "activities".
Nov 15 01:24:07 gleasonator mix[844098]: (ecto_sql 3.4.5) lib/ecto/adapters/sql.ex:593: Ecto.Adapters.SQL.raise_sql_call_error/1
Nov 15 01:24:07 gleasonator mix[844098]: (ecto 3.4.6) lib/ecto/repo/schema.ex:661: Ecto.Repo.Schema.apply/4
Nov 15 01:24:07 gleasonator mix[844098]: (ecto 3.4.6) lib/ecto/repo/schema.ex:263: anonymous fn/15 in Ecto.Repo.Schema.do_insert/4
Nov 15 01:24:07 gleasonator mix[844098]: (pleroma 2.2.0-628-g1172844e) lib/pleroma/web/activity_pub/activity_pub.ex:170: Pleroma.Web.ActivityPub.ActivityPub.insert_activity_with_expiration/3
Nov 15 01:24:07 gleasonator mix[844098]: (pleroma 2.2.0-628-g1172844e) lib/pleroma/web/activity_pub/activity_pub.ex:122: Pleroma.Web.ActivityPub.ActivityPub.insert/4
Nov 15 01:24:07 gleasonator mix[844098]: (pleroma 2.2.0-628-g1172844e) lib/pleroma/web/activity_pub/activity_pub.ex:358: Pleroma.Web.ActivityPub.ActivityPub.flag/1
Nov 15 01:24:07 gleasonator mix[844098]: (pleroma 2.2.0-628-g1172844e) lib/pleroma/web/mastodon_api/controllers/report_controller.ex:17: Pleroma.Web.MastodonAPI.ReportController.create/2
Nov 15 01:24:07 gleasonator mix[844098]: (pleroma 2.2.0-628-g1172844e) lib/pleroma/web/mastodon_api/controllers/report_controller.ex:5: Pleroma.Web.MastodonAPI.ReportController.action/2
Edited by Alex Gleason