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

[Bug]: outbound federation of comments not working on personal instance #3380

Closed
4 tasks done
dfyx opened this issue Jun 27, 2023 · 16 comments
Closed
4 tasks done

[Bug]: outbound federation of comments not working on personal instance #3380

dfyx opened this issue Jun 27, 2023 · 16 comments
Labels
bug Something isn't working

Comments

@dfyx
Copy link

dfyx commented Jun 27, 2023

Requirements

  • Is this a bug report? For questions or discussions use https://lemmy.ml/c/lemmy_support
  • Did you check to see if this issue already exists?
  • Is this only a single bug? Do not put multiple bugs in one issue.
  • Is this a backend issue? Use the lemmy-ui repo for UI / frontend issues.

Summary

(Second attempt, GitHub suddenly threw a 404 the first time I submitted this)

For the last few days, none of the comments I made on my personal instance have federated to other instances, effectively shadowbanning me from the fediverse. For example one of my latest comments:

This seems to have happened to all my comments from the last few days, so it's probably neither a problem specifically with 0.18 (which I installed yesterday) nor a simple delay.

Steps to Reproduce

  1. Register an account on https://lemmy.helios42.de/ (mention this bug and I'll manually unlock you)
  2. Comment on any federated post
  3. Wait a bit
  4. Notice that none of the other instances gets the comment

Technical Details

Installed as a docker stack on an Ubuntu 20.04 LTS host. Slightly modified the docker-compose.yml to accomodate this setup:

version: "3.9"

services:
  proxy:
    image: nginx:1-alpine
    networks:
      - default
      - traefik
    volumes:
      - ./nginx.conf:/etc/nginx/nginx.conf:ro,Z
    deploy:
      labels:
        traefik.enable: 'true'
        traefik.http.routers.lemmy.rule: 'Host(`lemmy.helios42.de`)'
        traefik.http.services.lemmy.loadbalancer.server.port: 1236

  lemmy:
    image: dessalines/lemmy:0.18
    hostname: lemmy
    restart: always
    environment:
      - RUST_LOG="warn,lemmy_server=info,lemmy_api=info,lemmy_api_common=info,lemmy_api_crud=info,lemmy_apub=info,lemmy_db_schema=info,lemmy_db_views=info,lemmy_db_views_actor=info,lemmy_db_views_moderator=info,lemmy_routes=info,lemmy_utils=info,lemmy_websocket=info"
    volumes:
      - ./lemmy.hjson:/config/config.hjson
  lemmy-ui:
    image: dessalines/lemmy-ui:0.18
    environment:
      # this needs to match the hostname defined in the lemmy service
      - LEMMY_UI_LEMMY_INTERNAL_HOST=lemmy:8536
      # set the outside hostname here
      - LEMMY_UI_LEMMY_EXTERNAL_HOST=lemmy.helios42.de
      - LEMMY_UI_HTTPS=true
    restart: always
  pictrs:
    image: asonix/pictrs:0.3.1
    # this needs to match the pictrs url in lemmy.hjson
    hostname: pictrs
    # we can set options to pictrs like this, here we set max. image size and forced format for conversion
    # entrypoint: /sbin/tini -- /usr/local/bin/pict-rs -p /mnt -m 4 --image-format webp
    environment:
      - PICTRS__API_KEY=redacted
      - RUST_LOG=debug
      - RUST_BACKTRACE=full
      - PICTRS__MEDIA__VIDEO_CODEC=vp9
      - PICTRS__MEDIA__GIF__MAX_WIDTH=256
      - PICTRS__MEDIA__GIF__MAX_HEIGHT=256
      - PICTRS__MEDIA__GIF__MAX_AREA=65536
      - PICTRS__MEDIA__GIF__MAX_FRAME_COUNT=400
    user: 991:991
    volumes:
      - pictrs:/mnt
    restart: always

  postgres:
    image: postgres:15-alpine
    # this needs to match the database host in lemmy.hson
    hostname: postgres
    environment:
      - POSTGRES_USER=lemmy
      - POSTGRES_PASSWORD=redacted
      - POSTGRES_DB=lemmy
    volumes:
      - postgres:/var/lib/postgresql/data
    restart: always

volumes:
  pictrs:
  postgres:

networks:
  traefik:
    external: true

Full logs of restarting the instance and creating one new comment (not the one in the example above):

2023-06-27T14:00:34.508242Z  INFO lemmy_db_schema::utils: Running Database migrations (This may take a long time)...
2023-06-27T14:00:34.510317Z  INFO lemmy_db_schema::utils: Database migrations complete.
2023-06-27T14:00:34.515172Z  INFO lemmy_server::code_migrations: Running user_updates_2020_04_02
2023-06-27T14:00:34.533598Z  INFO lemmy_server::code_migrations: 0 person rows updated.
2023-06-27T14:00:34.533903Z  INFO lemmy_server::code_migrations: Running community_updates_2020_04_02
2023-06-27T14:00:34.535100Z  INFO lemmy_server::code_migrations: 0 community rows updated.
2023-06-27T14:00:34.535184Z  INFO lemmy_server::code_migrations: Running post_updates_2020_04_03
2023-06-27T14:00:34.537564Z  INFO lemmy_server::code_migrations: 0 post rows updated.
2023-06-27T14:00:34.537644Z  INFO lemmy_server::code_migrations: Running comment_updates_2020_04_03
2023-06-27T14:00:34.554095Z  INFO lemmy_server::code_migrations: 0 comment rows updated.
2023-06-27T14:00:34.554238Z  INFO lemmy_server::code_migrations: Running private_message_updates_2020_05_05
2023-06-27T14:00:34.554800Z  INFO lemmy_server::code_migrations: 0 private message rows updated.
2023-06-27T14:00:34.554870Z  INFO lemmy_server::code_migrations: Running post_thumbnail_url_updates_2020_07_27
2023-06-27T14:00:34.556431Z  INFO lemmy_server::code_migrations: 0 Post thumbnail_url rows updated.
2023-06-27T14:00:34.556551Z  INFO lemmy_server::code_migrations: Running apub_columns_2021_02_02
2023-06-27T14:00:34.565398Z  INFO lemmy_server::code_migrations: Running instance_actor_2021_09_29
2023-06-27T14:00:34.572078Z  INFO lemmy_server::code_migrations: Running regenerate_public_keys_2022_07_05
2023-06-27T14:00:34.580605Z  INFO lemmy_server::code_migrations: Running initialize_local_site_2022_10_10
federation enabled, host is lemmy.helios42.de
Starting http server at 0.0.0.0:8536
2023-06-27T14:00:34.602026Z  INFO lemmy_server::scheduled_tasks: Updating active site and community aggregates ...
2023-06-27T14:00:34.969007Z  INFO lemmy_server::scheduled_tasks: Done.
2023-06-27T14:00:34.969020Z  INFO lemmy_server::scheduled_tasks: Updating hot ranks for all history...
2023-06-27T14:00:38.149238Z  INFO lemmy_server::scheduled_tasks: Done.
2023-06-27T14:00:38.149255Z  INFO lemmy_server::scheduled_tasks: Updating banned column if it expires ...
2023-06-27T14:00:38.160262Z  INFO lemmy_server::scheduled_tasks: Clearing old activities...
2023-06-27T14:00:38.639464Z  INFO lemmy_server::scheduled_tasks: Done.
2023-06-27T14:00:42.377796Z  WARN Error encountered while processing the incoming HTTP request: lemmy_server::root_span_builder: duplicate key value violates unique constraint "idx_activity_ap_id"
   0: lemmy_apub::insert_activity
           with ap_id=Url { scheme: "https", cannot_be_a_base: false, username: "", password: None, host: Some(Domain("kbin.social")), port: None, path: "/m/technology@beehaw.org/t/95758/-/comment/418226", query: None, fragment: None } local=false sensitive=false
             at crates/apub/src/lib.rs:159
   1: lemmy_apub::activities::create_or_update::comment::receive
             at crates/apub/src/activities/create_or_update/comment.rs:168
   2: lemmy_apub::activities::community::announce::receive
             at crates/apub/src/activities/community/announce.rs:141
   3: lemmy_server::root_span_builder::HTTP request
           with http.method=POST http.scheme="https" http.host=lemmy.helios42.de http.target=/inbox otel.kind="server" request_id=7d561e7c-4076-4eca-ad9b-f5da34e3c84f http.status_code=400 otel.status_code="OK"
             at src/root_span_builder.rs:16
LemmyError { message: None, inner: duplicate key value violates unique constraint "idx_activity_ap_id", context: SpanTrace [{ target: "lemmy_apub", name: "insert_activity", fields: "\u{1b}[3map_id\u{1b}[0m\u{1b}[2m=\u{1b}[0mUrl { scheme: \"https\", cannot_be_a_base: false, username: \"\", password: None, host: Some(Domain(\"kbin.social\")), port: None, path: \"/m/technology@beehaw.org/t/95758/-/comment/418226\", query: None, fragment: None } \u{1b}[3mlocal\u{1b}[0m\u{1b}[2m=\u{1b}[0mfalse \u{1b}[3msensitive\u{1b}[0m\u{1b}[2m=\u{1b}[0mfalse", file: "crates/apub/src/lib.rs", line: 159 }, { target: "lemmy_apub::activities::create_or_update::comment", name: "receive", file: "crates/apub/src/activities/create_or_update/comment.rs", line: 168 }, { target: "lemmy_apub::activities::community::announce", name: "receive", file: "crates/apub/src/activities/community/announce.rs", line: 141 }, { target: "lemmy_server::root_span_builder", name: "HTTP request", fields: "\u{1b}[3mhttp.method\u{1b}[0m\u{1b}[2m=\u{1b}[0mPOST \u{1b}[3mhttp.scheme\u{1b}[0m\u{1b}[2m=\u{1b}[0m\"https\" \u{1b}[3mhttp.host\u{1b}[0m\u{1b}[2m=\u{1b}[0mlemmy.helios42.de \u{1b}[3mhttp.target\u{1b}[0m\u{1b}[2m=\u{1b}[0m/inbox \u{1b}[3motel.kind\u{1b}[0m\u{1b}[2m=\u{1b}[0m\"server\" \u{1b}[3mrequest_id\u{1b}[0m\u{1b}[2m=\u{1b}[0m7d561e7c-4076-4eca-ad9b-f5da34e3c84f \u{1b}[3mhttp.status_code\u{1b}[0m\u{1b}[2m=\u{1b}[0m400 \u{1b}[3motel.status_code\u{1b}[0m\u{1b}[2m=\u{1b}[0m\"OK\"", file: "src/root_span_builder.rs", line: 16 }] }
2023-06-27T14:00:59.387150Z  WARN Error encountered while processing the incoming HTTP request: lemmy_server::root_span_builder: Other errors which are not explicitly handled
   0: lemmy_apub::activities::verify_person_in_community
             at crates/apub/src/activities/mod.rs:50
   1: lemmy_apub::activities::voting::vote::verify
             at crates/apub/src/activities/voting/vote.rs:57
   2: lemmy_apub::activities::community::announce::receive
             at crates/apub/src/activities/community/announce.rs:141
   3: lemmy_server::root_span_builder::HTTP request
           with http.method=POST http.scheme="https" http.host=lemmy.helios42.de http.target=/inbox otel.kind="server" request_id=7cef9436-4397-4448-9be1-a969850b3d9a http.status_code=400 otel.status_code="OK"
             at src/root_span_builder.rs:16
LemmyError { message: None, inner: Other errors which are not explicitly handled, context: SpanTrace [{ target: "lemmy_apub::activities", name: "verify_person_in_community", file: "crates/apub/src/activities/mod.rs", line: 50 }, { target: "lemmy_apub::activities::voting::vote", name: "verify", file: "crates/apub/src/activities/voting/vote.rs", line: 57 }, { target: "lemmy_apub::activities::community::announce", name: "receive", file: "crates/apub/src/activities/community/announce.rs", line: 141 }, { target: "lemmy_server::root_span_builder", name: "HTTP request", fields: "\u{1b}[3mhttp.method\u{1b}[0m\u{1b}[2m=\u{1b}[0mPOST \u{1b}[3mhttp.scheme\u{1b}[0m\u{1b}[2m=\u{1b}[0m\"https\" \u{1b}[3mhttp.host\u{1b}[0m\u{1b}[2m=\u{1b}[0mlemmy.helios42.de \u{1b}[3mhttp.target\u{1b}[0m\u{1b}[2m=\u{1b}[0m/inbox \u{1b}[3motel.kind\u{1b}[0m\u{1b}[2m=\u{1b}[0m\"server\" \u{1b}[3mrequest_id\u{1b}[0m\u{1b}[2m=\u{1b}[0m7cef9436-4397-4448-9be1-a969850b3d9a \u{1b}[3mhttp.status_code\u{1b}[0m\u{1b}[2m=\u{1b}[0m400 \u{1b}[3motel.status_code\u{1b}[0m\u{1b}[2m=\u{1b}[0m\"OK\"", file: "src/root_span_builder.rs", line: 16 }] }
2023-06-27T14:01:48.135018Z  WARN Error encountered while processing the incoming HTTP request: lemmy_server::root_span_builder: couldnt_find_post: Record not found
   0: lemmy_api_crud::post::read::perform
           with self=GetPost { id: Some(PostId(4261)), comment_id: None, auth: None }
             at crates/api_crud/src/post/read.rs:26
   1: lemmy_server::root_span_builder::HTTP request
           with http.method=GET http.scheme="http" http.host=lemmy.helios42.de http.target=/api/v3/post otel.kind="server" request_id=d301e92d-a0a9-4241-8fbd-dd407f067e82 http.status_code=404 otel.status_code="OK"
             at src/root_span_builder.rs:16
LemmyError { message: Some("couldnt_find_post"), inner: Record not found, context: SpanTrace [{ target: "lemmy_api_crud::post::read", name: "perform", fields: "\u{1b}[3mself\u{1b}[0m\u{1b}[2m=\u{1b}[0mGetPost { id: Some(PostId(4261)), comment_id: None, auth: None }", file: "crates/api_crud/src/post/read.rs", line: 26 }, { target: "lemmy_server::root_span_builder", name: "HTTP request", fields: "\u{1b}[3mhttp.method\u{1b}[0m\u{1b}[2m=\u{1b}[0mGET \u{1b}[3mhttp.scheme\u{1b}[0m\u{1b}[2m=\u{1b}[0m\"http\" \u{1b}[3mhttp.host\u{1b}[0m\u{1b}[2m=\u{1b}[0mlemmy.helios42.de \u{1b}[3mhttp.target\u{1b}[0m\u{1b}[2m=\u{1b}[0m/api/v3/post \u{1b}[3motel.kind\u{1b}[0m\u{1b}[2m=\u{1b}[0m\"server\" \u{1b}[3mrequest_id\u{1b}[0m\u{1b}[2m=\u{1b}[0md301e92d-a0a9-4241-8fbd-dd407f067e82 \u{1b}[3mhttp.status_code\u{1b}[0m\u{1b}[2m=\u{1b}[0m404 \u{1b}[3motel.status_code\u{1b}[0m\u{1b}[2m=\u{1b}[0m\"OK\"", file: "src/root_span_builder.rs", line: 16 }] }
2023-06-27T14:02:04.763241Z  INFO HTTP request{http.method=POST http.scheme="https" http.host=lemmy.helios42.de http.target=/api/v3/comment otel.kind="server" request_id=e3719150-db38-4e45-abee-9027ec6c1e09}:send:send_lemmy_activity: lemmy_apub::activities: Sending activity https://lemmy.helios42.de/activities/create/df819755-163b-42b6-a655-c947ec43286b
2023-06-27T14:02:21.253665Z  WARN Error encountered while processing the incoming HTTP request: lemmy_server::root_span_builder: Fetched remote object https://latte.isnot.coffee/u/chickpea which was deleted
   0: lemmy_apub::http::site::get_apub_site_inbox
             at crates/apub/src/http/site.rs:40
   1: lemmy_server::root_span_builder::HTTP request
           with http.method=POST http.scheme="https" http.host=lemmy.helios42.de http.target=/site_inbox otel.kind="server" request_id=f9786de3-bed1-4bf4-948d-39b84df17ad5 http.status_code=400 otel.status_code="OK"
             at src/root_span_builder.rs:16
LemmyError { message: None, inner: Fetched remote object https://latte.isnot.coffee/u/chickpea which was deleted, context: SpanTrace [{ target: "lemmy_apub::http::site", name: "get_apub_site_inbox", file: "crates/apub/src/http/site.rs", line: 40 }, { target: "lemmy_server::root_span_builder", name: "HTTP request", fields: "\u{1b}[3mhttp.method\u{1b}[0m\u{1b}[2m=\u{1b}[0mPOST \u{1b}[3mhttp.scheme\u{1b}[0m\u{1b}[2m=\u{1b}[0m\"https\" \u{1b}[3mhttp.host\u{1b}[0m\u{1b}[2m=\u{1b}[0mlemmy.helios42.de \u{1b}[3mhttp.target\u{1b}[0m\u{1b}[2m=\u{1b}[0m/site_inbox \u{1b}[3motel.kind\u{1b}[0m\u{1b}[2m=\u{1b}[0m\"server\" \u{1b}[3mrequest_id\u{1b}[0m\u{1b}[2m=\u{1b}[0mf9786de3-bed1-4bf4-948d-39b84df17ad5 \u{1b}[3mhttp.status_code\u{1b}[0m\u{1b}[2m=\u{1b}[0m400 \u{1b}[3motel.status_code\u{1b}[0m\u{1b}[2m=\u{1b}[0m\"OK\"", file: "src/root_span_builder.rs", line: 16 }] }

Version

both BE 0.17.4 and BE 0.18

Lemmy Instance URL

lemmy.helios42.de

@RocketDerp

This comment was marked as abuse.

@dfyx
Copy link
Author

dfyx commented Jun 27, 2023

Last week, everything worked. I can't tell exactly when it stopped but at least 4 days ago. I've restarted the container a few times but as far as I can remember, I haven't changed anything about the configuration in that timeframe.

Edit: thinking back, it might have coincided with the upgrade from 0.17.3 to 0.17.4 but I can't be sure.

@RocketDerp

This comment was marked as abuse.

@dfyx
Copy link
Author

dfyx commented Jun 27, 2023

I approved your account

@RocketDerp

This comment was marked as abuse.

@dfyx
Copy link
Author

dfyx commented Jun 27, 2023

So my instance is sending malformed requests, possibly with a single incorrect parameter and we have no logging that can tell us what exactly those requests contain?

@RocketDerp

This comment was marked as abuse.

@dfyx
Copy link
Author

dfyx commented Jun 28, 2023

I'd rather not reset my instance and instead focus on finding a way to debug this so we can hopefully find a solution for everyone else who might have the same problem in the future.

I'm pretty sure I haven't changed anything about my configuration that could have influenced outgoing requests. All networking is the same as before, including hostnames. My best guess is that something broke during a restart and now has to be fixed in the database.

Unfortunately, I'm not very familiar with rust so I have no clue how I could debug this. If anyone has a good idea, I could easily spin up a second instance so I have something to test against without spamming real communities.

@RocketDerp

This comment was marked as abuse.

@dfyx
Copy link
Author

dfyx commented Jun 28, 2023

Well, guess I'll have to learn Rust unless someone else can tell me how to log the full request or at least more details about what causes the http 400.

@smorks
Copy link
Contributor

smorks commented Jun 28, 2023

i was going to try the "mirror" method listed here: https://stackoverflow.com/a/67127911 to try and debug #3354. maybe that will help here too?

@dfyx
Copy link
Author

dfyx commented Jun 29, 2023

Alright, I built a small setup that puts mitmproxy between nginx and the backend. Here's a subscribe request:

Request headers:

POST /inbox HTTP/1.0
X-Real-IP: 10.0.2.25
Host: lemmy:8536
X-Forwarded-For: 10.0.0.2, 10.0.2.25
Connection: close
Content-Length: 914
User-Agent: Lemmy/0.18.0; +https://lemmy.helios42.de
Accept: */*
Content-Type: application/activity+json
Date: Thu, 29 Jun 2023 13:07:34 GMT
Digest: SHA-256=i7WvKDyIbBTs6R7GoilDS9u1recJrX13oVqQnpKoGgQ=
Signature: keyId="https://lemmy.helios42.de/u/dfyx#main-key",algorithm="hs2019",headers="(request-target) content-type date digest host",signature="SCiYhZLbjw1Y5uwLpt8xIgWCz6LErBWJBU5/c5ubg0KxL9Yr5vwYgxE6kzpT3xNxOFbU53NJLibRP6S2DflweMZFNGGAIE310Vi1B4nhWLB04Qf3S8jLYR8OFgOoTRvmx9MuQC6FBcim8f3Af5VJV3fOVv03BDTZEbUdy8gHFFsalyu1Rj81O0fD2QnPi5NxV1iSVPoAcOjNaJqZI/AJ1Re3m51CSR4n1/MzMzb6zFu81B6HuJtcFAV9Mo+vGCCpNZmQkcxkDJoNgc/oWwDLOXo/yiennokysTDWQg77e5rYm4mJxaYRU4o0tPeUqfr6tmSsQoEUpV9+gktwG8m6Gg=="
X-Forwarded-Host: lemmy-debug.helios42.de
X-Forwarded-Port: 443
X-Forwarded-Proto: https
X-Forwarded-Server: 7ee5f7197c73
Accept-Encoding: gzip

Request body:

{
    "@context": [
        "https://www.w3.org/ns/activitystreams",
        "https://w3id.org/security/v1",
        {
            "ChatMessage": "litepub:ChatMessage",
            "commentsEnabled": "pt:commentsEnabled",
            "distinguished": "lemmy:distinguished",
            "expires": "as:endTime",
            "identifier": "sc:identifier",
            "language": "sc:inLanguage",
            "lemmy": "https://join-lemmy.org/ns#",
            "litepub": "http://litepub.social/ns#",
            "matrixUserId": "lemmy:matrixUserId",
            "moderators": {
                "@id": "lemmy:moderators",
                "@type": "@id"
            },
            "postingRestrictedToMods": "lemmy:postingRestrictedToMods",
            "pt": "https://joinpeertube.org/ns#",
            "removeData": "lemmy:removeData",
            "sc": "http://schema.org/",
            "sensitive": "as:sensitive",
            "stickied": "lemmy:stickied"
        }
    ],
    "actor": "https://lemmy.helios42.de/u/dfyx",
    "id": "https://lemmy.helios42.de/activities/follow/b3b76cc3-5394-4265-a667-789123ad2b27",
    "object": "https://lemmy-debug.helios42.de/c/testcommunity",
    "to": [
        "https://lemmy-debug.helios42.de/c/testcommunity"
    ],
    "type": "Follow"
}

Response

HTTP/1.0 400 Bad Request
content-length: 44
vary: Origin, Access-Control-Request-Method, Access-Control-Request-Headers
content-type: text/plain
date: Thu, 29 Jun 2023 13:09:30 GMT

Response body limit was reached during fetch

Debug instance logs: (might be from a different identical request, I tried multiple times)

2023-06-29T13:09:30.176217Z  WARN Error encountered while processing the incoming HTTP request: lemmy_server::root_span_builder: Response body limit was reached during fetch
   0: lemmy_server::root_span_builder::HTTP request
           with http.method=POST http.scheme="https" http.host=lemmy-debug.helios42.de http.target=/inbox otel.kind="server" request_id=d0fee7f7-d5c5-4255-b54f-6ae35af0cfc8 http.status_code=400 otel.status_code="OK"
             at src/root_span_builder.rs:16
LemmyError { message: None, inner: Response body limit was reached during fetch, context: SpanTrace [{ target: "lemmy_server::root_span_builder", name: "HTTP request", fields: "\u{1b}[3mhttp.method\u{1b}[0m\u{1b}[2m=\u{1b}[0mPOST \u{1b}[3mhttp.scheme\u{1b}[0m\u{1b}[2m=\u{1b}[0m\"https\" \u{1b}[3mhttp.host\u{1b}[0m\u{1b}[2m=\u{1b}[0mlemmy-debug.helios42.de \u{1b}[3mhttp.target\u{1b}[0m\u{1b}[2m=\u{1b}[0m/inbox \u{1b}[3motel.kind\u{1b}[0m\u{1b}[2m=\u{1b}[0m\"server\" \u{1b}[3mrequest_id\u{1b}[0m\u{1b}[2m=\u{1b}[0md0fee7f7-d5c5-4255-b54f-6ae35af0cfc8 \u{1b}[3mhttp.status_code\u{1b}[0m\u{1b}[2m=\u{1b}[0m400 \u{1b}[3motel.status_code\u{1b}[0m\u{1b}[2m=\u{1b}[0m\"OK\"", file: "src/root_span_builder.rs", line: 16 }] }

Essentially the same for posting a comment, except of course for the different request body.

Edit: updated for readability

@RocketDerp

This comment was marked as abuse.

@dfyx
Copy link
Author

dfyx commented Jun 29, 2023

Okay, I'm a step closer. The problem isn't in the requests my instance sends but that the receiving instance sends its own requests back (probably to get public keys and further info)

Seems like my main instance generally replies with HTML when it should reply with JSON.

For a simple example, compare the outputs of curl -H 'Accept: application/activity+json' https://lemmy.helios42.de/c/foxplushies and curl -H 'Accept: application/activity+json' https://lemmy-debug.helios42.de/c/testcommunity

Edit: a force restart of the nginx container has finally solved the problem. Seems like I've had a broken config nginx.conf at some point and even after I changed it, docker stack deploy didn't restart the container.

@dfyx dfyx closed this as completed Jun 29, 2023
@graphit0
Copy link

graphit0 commented Jul 12, 2023

Struggling seemingly with the same issue, but am just a user; don't know how to troubleshoot the cause. @dfyx Could you please tell what was wrong with the nginx.conf ?

@dfyx
Copy link
Author

dfyx commented Jul 12, 2023

Definitely not the same issue. Beehaw replies correctly to curl -H 'Accept: application/activity+json' https://beehaw.org/c/support. I guess their problem is more along the lines of too much server load.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

4 participants