Not resolving .jl links if https://juliaregistries.github.io doesn't have it

I’ve noticed that discourse has been eagerly putting links to https://juliaregistries.github.io for anything of the form [A-Za-z]+\.jl. However, it is a bit too eager in doing so in many places where the project is shared that isn’t in the General Repository.

We should make it such that it only generates links if it actually is in the General Repository.

See previous thread for some more context about the current mechanism:

The problem is that discourse provides only quite basic tools. The linkification is done via regexes and these cannot perform additional logic to e.g. check whether the package actually exists in General.

If anything, we could try to make the script that generates the redirects smarter somehow. Although I don’t see how it could divine the existence of some package that’s not registered in General.

1 Like

But the page NonExistingPackage.jl points to is clear about that and suggests searching on the internet as an alternative. What do you suggest instead as a practical solution? As explained above, it’s not technically feasible to linkify only certain patterns but not others.

2 Likes

An alternative I had in mind, is for it to just link back to the current discourse thread that send it there. Perhaps, this might be technically feasible, not sure if it is any more or less confusing.

Links are opened in a new tab anyway, so you’d end up with two tabs on the same page. That looks confusing to me.

3 Likes