Open brendanheywood opened 7 years ago
Can we not link if a single word and at the beginning of a sentence.
We should probably hold off making changes until an language implementations has come through. I am guessing that with the use of upper case in some languages (eg German use of upper case in nouns) we will have to force quotes.
Yeah my gut says the more workarounds we add the more edge cases we will create, I think just forcing quotes depending on the context (eg in discussions) is simple and understandable.
Another example with a route called 'What':
As we go more multi lingual this will get trickier, so that strengthens the forced quotes idea in certain contexts (if not all?)
This one is even weirder:
This thread is in australia.
'Matt' is a route in Kalymnos: https://www.thecrag.com/climbing/greece/kalymnos/route/241111167 'Everyone' is a route in Korea: https://www.thecrag.com/climbing/south-korea/route/946916553
Why on earth are they linking - but also if they are linking then it must be doing a horrendously expensive scan of basically every route name in the db to find potential matches.
Discussion in the blue mountains linked the word 'NEW' to a route in tasmania
and the word IF to a route in Frog
There again are outside the scope of this discussion so not sure what is going on, but there are also a bunch of other auto links to routes inside the blue mountains which probably also don't make sense either
Oh wow this one is pretty bad as it has auto linked the word 'Climbing' which is a gym route:
Another example of an auto linked name, but from an outside forum conversation and linking into a gym route name which I think should never happen:
From @gogulfresh via https://github.com/theCrag/website/issues/3314
What happened? A link to a route is created where it shouldn't/I don't want. How can linking be suppressed?
Example url(s) to reproduce the problem: https://www.thecrag.com/climbing/austria/route/1529281464 The word "spalt" in the description links to the route "spalt" https://www.thecrag.com/climbing/austria/route/1532385009 spalt ~= crack in german, thus in the text it is refering to a crack of this route and not the route "spalt"
What you expected:
Another one: https://www.thecrag.com/climbing/austria/route/1880663691
Verschneidung == book/corner/dihedral (What is the correct translation?)
Another one:
Ugghh so many duds in a single thread, and picked up randomly from crags all over the world:
I got the grumps with this and dug around a little, and it turns out we always went up a node and then searched inside that, so if the discussion was at the australia level then we searched the entire world looking for matches. I've refined this a little, so it only searchs the TLC, or "this" node, or a routes parent cliff and added an explicit exclusion for the world. I think this is about 60% of the solution. I still think even within a crag there are too may false matches but at least they are not now from random crags around the world.
From @gogulfresh via #3314 ...
- [ ] Have it documented here https://www.thecrag.com/en/article/updatingdescriptions
Please do not add the details there, but add only a link to the (still to be done) description in https://www.thecrag.com/en/article/formattingtext#internal-links because the links do work in many other text fields than route descriptions.
Thanks for all the comments. This "feature" has become more of a pain than anything else and we are considering to remove it completely. the idea is to require hyphens or simialr to create the link but remove all links that are strictly text based as in the examples above.
If you have any commenst on this, please put them here.
eg in:
This is linking to a route in a completely different crag. I'm not sure exactly what the current business rules are but I think this is too much. Either we don't link for single word route names, or we just make it simple and require quotes. I don't think simply blacklisting certain names will be that productive for this bug.