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

Unrelated opengraph link attached to a post #8308

Open
Flaburgan opened this issue Oct 14, 2021 · 7 comments
Open

Unrelated opengraph link attached to a post #8308

Flaburgan opened this issue Oct 14, 2021 · 7 comments

Comments

@Flaburgan
Copy link
Member

I had a super weird (for the users) bug on this post: an opengraph suggestion, totally unrelated, is displayed below it. Do we have an id collusion in the database with another post?

I didn't check the changelog of the new version pushed by #8307 but I don't think it would solve it, would it?

@goobertron
Copy link

goobertron commented Oct 14, 2021

Edit: see next comment below – my case is covered by an earlier Github ticket.

Just in case it is related and helps debug this, I've noticed an OpenGraph oddity of an incorrect but related preview appearing.

For the past few years, every OG preview on pod.orkz.net for a post by Commits to Diaspora has started 'When I viewed my profile, I noticed that the light gray background counter for the account I have in my aspects doesn't seem to span behind more than 2 digits.' On joindiaspora.com, the text starts 'for now youtube, vimeo and soundcloud embedding and external links preview supports only english letters.'

The link in both cases is simply https://github.com/diaspora/diaspora.

I haven't searched Github for these issues, but I assume they were the most recently posted or most recently updated issue in the Github repo when this feature was first activated for each of the pods.

Hope that's useful – if not, ignore it.

@SuperTux88
Copy link
Member

This issue is really weird, since there isn't an URL in this post at all. I have no idea how this could happen, id collisions shouldn't happen unless you somehow manually modify the database and create an inconsistency, which then maybe leads to future problems.

Do you have anything in the logs? Was the opengraph metadata fetched or was it already in the database?

The behavior goob is describing is known and there is already an issue for that: #4966 (diaspora only fetches the info once, and if the opengraph metadata changes and somebody posts the exact same URL again it uses the already fetched metadata)

@Pafzedog
Copy link

for information, I copy-pasted all text of the original post in a new post of my account and the same opengraph suggestion is rising.
screenshot

@tclaus
Copy link
Member

tclaus commented Oct 15, 2021

This is because of the last sentence:
sont devenues parfois des ami.es voire plus… Il m’en reste quelque un.es à rencontrer IRL
In Diaspora code two URLs are found:
ami.es (the first one that will be uses as open graph content)
and
un.es.

The first link is redirected to boxen1.

So this is a reproducible glitch. Don't use the dot without following space.

@goobertron
Copy link

This is because of the last sentence:
sont devenues parfois des ami.es voire plus… Il m’en reste quelque un.es à rencontrer IRL
In Diaspora code two URLs are found:
ami.es (the first one that will be uses as open graph content)
and
un.es.

Well spotted!

It's odd that an OG preview is fetched even though those aren't converted to links in the post itself.

  1. Do we want to be fetching OG previews for a domain name that is not a full URL (i.e. preceded by http[s]://)?
  2. If we do, are ami.es and un.es a common way of saying ami/amies and uns/unes? – @Flaburgan? If they are, and this is something that francophone community members are likely to post frequently, is an exception to OG behaviour needed for those cases?

Personally I'd imagine that if text in a post is not something that is converted into a link by diaspora's code, we shouldn't be fetching an OG preview for it. But I'd be interested to hear what other people think.

@tclaus
Copy link
Member

tclaus commented Oct 15, 2021

Maybe its a good idea to suppress the auto.generation of these links. Just for the notes, in my 180.000 open_graph_links, I don't have ami.es nor us.es or variants in any urls.

@Flaburgan
Copy link
Member Author

Personally I'd imagine that if text in a post is not something that is converted into a link by diaspora's code, we shouldn't be fetching an OG preview for it.

I totally agree with this, this is the bug to fix here.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

5 participants