[bug] Inconsistent treatment of federated hashtags containing unicode #568

Open
opened 2023-06-15 12:41:23 +00:00 by timorl · 3 comments
Contributor

Your setup

From source

Extra details

Gentoo

Version

v3.9.3

PostgreSQL version

15.3

What were you trying to do?

Check how Akkoma treats hashtags with some unicode characters, as inspired by this post. In particular I checked the hashtags for #c and #ć.

What did you expect to happen?

That Akkoma, the great software that it is, would treat #ć as it's own separate thing from #c, and viewing either would show only posts tagged with it.

Failing that, that it would behave like Mastodon and consistently treat them as one hashtag.

What actually happened?

The hashtag #ć exists, but doesn't contain posts tagged with #ć, when they are federated from Mastodon. The hashtag #c contains these posts. Locally made posts with either hashtag are treated as expected, i.e. they only end up in the correct hashtags.

Logs

No response

Severity

I can manage

Have you searched for this issue?

  • I have double-checked and have not found this issue mentioned anywhere.
### Your setup From source ### Extra details Gentoo ### Version v3.9.3 ### PostgreSQL version 15.3 ### What were you trying to do? Check how Akkoma treats hashtags with some unicode characters, as inspired by [this post](https://social.wuatek.is/notice/AWiNtdZxj4B7ca1oxs). In particular I checked the hashtags for #c and #ć. ### What did you expect to happen? That Akkoma, the great software that it is, would treat #ć as it's own separate thing from #c, and viewing either would show only posts tagged with it. Failing that, that it would behave like Mastodon and consistently treat them as one hashtag. ### What actually happened? The hashtag #ć exists, but doesn't contain posts tagged with #ć, when they are federated from Mastodon. The hashtag #c contains these posts. Locally made posts with either hashtag are treated as expected, i.e. they only end up in the correct hashtags. ### Logs _No response_ ### Severity I can manage ### Have you searched for this issue? - [x] I have double-checked and have not found this issue mentioned anywhere.
timorl added the
bug
label 2023-06-15 12:41:23 +00:00
Author
Contributor

I expect this is because masto butchers some metadata around hashtags and akko just trusts the federated metadata. I'm not sure this isn't "working as intended", but I would suggest that at least adding unicode hashtags to federated posts (since removing the external ones might cause other kinds of confusion) would be closer to expected behaviour.

I expect this is because masto butchers some metadata around hashtags and akko just trusts the federated metadata. I'm not sure this isn't "working as intended", but I would suggest that at least adding unicode hashtags to federated posts (since removing the external ones might cause other kinds of confusion) would be closer to expected behaviour.

Hello there! As a certified forklift driver, I can confirm that there seems to be an issue with Mastodon. It appears that Akkoma-FE may also be mishandling it, but the root cause of the problem lies with Mastodon. Here's what I found:

Mastodon seems to be federating the hashtag as a tag with the following properties:

{
    "type": "Hashtag",
    "href": "https://kampa.si/tags/c",
    "name": "#c"
}

However, the HTML being sent has a href attribute that does not match the ActivityPub tag. Here's what the HTML looks like:

<a href="https://kampa.si/tags/%C4%87" class="mention hashtag" rel="tag">#<span>ć</span></a>

As a forklift driver, I would suggest reporting this issue to Mastodon instead, as they are the ones responsible for federating the hashtag in the first place. I hope this helps!

Hello there! As a certified forklift driver, I can confirm that there seems to be an issue with Mastodon. It appears that Akkoma-FE may also be mishandling it, but the root cause of the problem lies with Mastodon. Here's what I found: Mastodon seems to be federating the hashtag as a tag with the following properties: ``` { "type": "Hashtag", "href": "https://kampa.si/tags/c", "name": "#c" } ``` However, the HTML being sent has a `href` attribute that does not match the ActivityPub tag. Here's what the HTML looks like: ``` <a href="https://kampa.si/tags/%C4%87" class="mention hashtag" rel="tag">#<span>ć</span></a> ``` As a forklift driver, I would suggest reporting this issue to Mastodon instead, as they are the ones responsible for federating the hashtag in the first place. I hope this helps!
Author
Contributor

Yeah, I guess this is much more of a Mastodon-side problem, and perhaps fixing issues arising due to that in Akkoma might be a waste of time. The only problem is, I suspect they will not want to fix this. ;_;

Anyway, reported there as well.

Yeah, I guess this is much more of a Mastodon-side problem, and perhaps fixing issues arising due to that in Akkoma might be a waste of time. The only problem is, I suspect they will not want to fix this. ;_; Anyway, [reported there as well](https://github.com/mastodon/mastodon/issues/25451).
Sign in to join this conversation.
No milestone
No project
No assignees
2 participants
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference: AkkomaGang/akkoma#568
No description provided.