matrix-org / matrix-appservice-irc

Node.js IRC bridge for Matrix
Apache License 2.0
460 stars 149 forks source link

Replies to messages containing a quote #1748

Open progval opened 1 year ago

progval commented 1 year ago

Initial message:

{
  "content": {
    "body": "Helge: Someone replied to you on IRC but you can't see it from Matrix:\n\n> 14:16:28 <fr33domlover> Helge[m]: I haven't looked into it, indeed it seems wrong. The easiest fix is probably to set the reference manually in the spec. A better solution is to check why bikeshed's specref data is outdated\n> 14:17:19 <fr33domlover> I don't have the capacity for this right now, but if you do, we'll both benefit ^_^\n> 14:18:54 <fr33domlover> Bikeshed is very leaning towards HTML/CSS specs, that's what it was originally made for and still used for, it's not a perfect general-purpose tool but it's the best we have\n> 14:20:02 <fr33domlover> Ideally we'd have our own tool for Fediverse-related specs, that auto-links vocabulary terms and has clauses for the common things without requiring custom tricks\n",
    "format": "org.matrix.custom.html",
    "formatted_body": "<p><a href=\"https://matrix.to/#/@helgek:matrix.org\">Helge</a>: Someone replied to you on IRC but you can't see it from Matrix:</p>\n<blockquote>\n<p>14:16:28 &lt;fr33domlover&gt; Helge[m]: I haven't looked into it, indeed it seems wrong. The easiest fix is probably to set the reference manually in the spec. A better solution is to check why bikeshed's specref data is outdated<br>14:17:19 &lt;fr33domlover&gt; I don't have the capacity for this right now, but if you do, we'll both benefit ^_^<br>14:18:54 &lt;fr33domlover&gt; Bikeshed is very leaning towards HTML/CSS specs, that's what it was originally made for and still used for, it's not a perfect general-purpose tool but it's the best we have<br>14:20:02 &lt;fr33domlover&gt; Ideally we'd have our own tool for Fediverse-related specs, that auto-links vocabulary terms and has clauses for the common things without requiring custom tricks</p>\n</blockquote>\n",
    "msgtype": "m.text"
  },
  "origin_server_ts": 1687895606967,
  "sender": "@pinkie:matrix.org",
  "type": "m.room.message",
  "unsigned": {
    "age": 308,
    "transaction_id": "m1687895606781.4"
  },
  "event_id": "$sIkK8Pec8f8UKaHm615l2Rs5oDXGZ1-dkh1ALKRq7NA",
  "room_id": "!MMvWLbDxskQNpEeuas:libera.chat"
}

reply:

{
  "content": {
    "body": "> <@pinkie:matrix.org> Helge: Someone replied to you on IRC but you can't see it from Matrix:\n> \n> > 14:16:28 <fr33domlover> Helge[m]: I haven't looked into it, indeed it seems wrong. The easiest fix is probably to set the reference manually in the spec. A better solution is to check why bikeshed's specref data is outdated\n> > 14:17:19 <fr33domlover> I don't have the capacity for this right now, but if you do, we'll both benefit ^_^\n> > 14:18:54 <fr33domlover> Bikeshed is very leaning towards HTML/CSS specs, that's what it was originally made for and still used for, it's not a perfect general-purpose tool but it's the best we have\n> > 14:20:02 <fr33domlover> Ideally we'd have our own tool for Fediverse-related specs, that auto-links vocabulary terms and has clauses for the common things without requiring custom tricks\n\nThank you. I'm kind of using https://socialhub.activitypub.rocks/t/get-fep-included-in-specref/3303 as a tracking thing.",
    "format": "org.matrix.custom.html",
    "formatted_body": "<mx-reply><blockquote><a href=\"https://matrix.to/#/!MMvWLbDxskQNpEeuas:libera.chat/$sIkK8Pec8f8UKaHm615l2Rs5oDXGZ1-dkh1ALKRq7NA?via=libera.chat&via=matrix.org&via=community.rs\">In reply to</a> <a href=\"https://matrix.to/#/@pinkie:matrix.org\">@pinkie:matrix.org</a><br><p><a href=\"https://matrix.to/#/@helgek:matrix.org\">Helge</a>: Someone replied to you on IRC but you can't see it from Matrix:</p>\n<blockquote>\n<p>14:16:28 &lt;fr33domlover&gt; Helge[m]: I haven't looked into it, indeed it seems wrong. The easiest fix is probably to set the reference manually in the spec. A better solution is to check why bikeshed's specref data is outdated<br />14:17:19 &lt;fr33domlover&gt; I don't have the capacity for this right now, but if you do, we'll both benefit ^_^<br />14:18:54 &lt;fr33domlover&gt; Bikeshed is very leaning towards HTML/CSS specs, that's what it was originally made for and still used for, it's not a perfect general-purpose tool but it's the best we have<br />14:20:02 &lt;fr33domlover&gt; Ideally we'd have our own tool for Fediverse-related specs, that auto-links vocabulary terms and has clauses for the common things without requiring custom tricks</p>\n</blockquote>\n</blockquote></mx-reply>Thank you. I'm kind of using https://socialhub.activitypub.rocks/t/get-fep-included-in-specref/3303 as a tracking thing.",
    "m.relates_to": {
      "m.in_reply_to": {
        "event_id": "$sIkK8Pec8f8UKaHm615l2Rs5oDXGZ1-dkh1ALKRq7NA"
      }
    },
    "msgtype": "m.text"
  },
  "origin_server_ts": 1687931142181,
  "sender": "@helgek:matrix.org",
  "type": "m.room.message",
  "unsigned": {
    "age": 1096288
  },
  "event_id": "$FEgJX_flBYaofRP7blangKiBZIjcMo997xVRuvKkkzc",
  "room_id": "!MMvWLbDxskQNpEeuas:libera.chat"
}

which sent this to IRC:

<Helge[m]> <val[m]> "Helge: Someone replied to you on..." <- > <@pinkie:matrix.org> Helge: Someone replied to you on IRC but you can't see it from Matrix:... (full message at <https://libera.ems.host/_matrix/media/v3/download/libera.chat/917d0888a7e722971d94e77ec91635add16e6c7b>)

Instead, it should have sent this:

<Helge[m]> <val[m]> "Helge: Someone replied to you on..." <- Thank you. I'm kind of using https://socialhub.activitypub.rocks/t/get-fep-included-in-specref/3303 as a tracking thing.