[Django] #26077: Change latin map in urlify to correctly translate Umlauts

7 views
Skip to first unread message

Django

unread,
Jan 13, 2016, 4:05:46 AM1/13/16
to django-...@googlegroups.com
#26077: Change latin map in urlify to correctly translate Umlauts
-------------------------------+--------------------
Reporter: shredding | Owner: nobody
Type: Uncategorized | Status: new
Component: Uncategorized | Version: 1.9
Severity: Normal | Keywords:
Triage Stage: Unreviewed | Has patch: 0
Easy pickings: 0 | UI/UX: 0
-------------------------------+--------------------
The latin map translates the umlauts ä, ü and ö to a, u and o:

https://github.com/django/django/blob/master/django/contrib/admin/static/admin/js/urlify.js#L5-L16

The correct way of doing this would be ae, ue and oe (it's the correct
writing and preferred for seo reasons).

--
Ticket URL: <https://code.djangoproject.com/ticket/26077>
Django <https://code.djangoproject.com/>
The Web framework for perfectionists with deadlines.

Django

unread,
Jan 13, 2016, 6:59:08 AM1/13/16
to django-...@googlegroups.com
#26077: Change latin map in urlify to correctly translate Umlauts
-------------------------------+--------------------------------------

Reporter: shredding | Owner: nobody
Type: Uncategorized | Status: new
Component: Uncategorized | Version: 1.9
Severity: Normal | Resolution:
Keywords: | Triage Stage: Unreviewed
Has patch: 0 | Needs documentation: 0
Needs tests: 0 | Patch needs improvement: 0

Easy pickings: 0 | UI/UX: 0
-------------------------------+--------------------------------------
Changes (by timgraham):

* needs_better_patch: => 0
* needs_tests: => 0
* needs_docs: => 0


Comment:

Could you provide a reference for the claim or point to another system
that has the proposed behavior? Thanks.

--
Ticket URL: <https://code.djangoproject.com/ticket/26077#comment:1>

Django

unread,
Jan 13, 2016, 7:11:17 AM1/13/16
to django-...@googlegroups.com
#26077: Change latin map in urlify to correctly translate Umlauts
-------------------------------+--------------------------------------

Reporter: shredding | Owner: nobody
Type: Uncategorized | Status: new
Component: Uncategorized | Version: 1.9
Severity: Normal | Resolution:
Keywords: | Triage Stage: Unreviewed

Has patch: 0 | Needs documentation: 0
Needs tests: 0 | Patch needs improvement: 0

Easy pickings: 0 | UI/UX: 0
-------------------------------+--------------------------------------

Comment (by shredding):

I'll look for references, but the basic point is, that the url version of
an german umlaut should be like proposed.

If you have a website with mydomain.de/apple and mydomain.de/apples than
the german version of it should be mydomain.de/apfel and
mydomain.de/aepfel

In other cases, where you do not have a singular / plural ambiguity the
slugified version is simply a misspelled version of the original one and
this is noted by google (for the german rätsel, aka riddle=

https://www.google.com/search?q=ratsel -> google tries to autocorrect you
to rätsel
https://www.google.com/search?q=raetsel -> google accepts the query as
rätsel

This link describes the issue: http://blog.webcertain.com/do-umlauts-
matter-how-to-handle-the-most-annoying-characters-in-german-
seo-2/10/04/2014/

TL;DR: Converting ä to a results in misspelled words.

--
Ticket URL: <https://code.djangoproject.com/ticket/26077#comment:2>

Django

unread,
Jan 13, 2016, 8:07:31 AM1/13/16
to django-...@googlegroups.com
#26077: Change latin map in urlify to correctly translate Umlauts
-------------------------------+--------------------------------------

Reporter: shredding | Owner: nobody
Type: Uncategorized | Status: new
Component: Uncategorized | Version: 1.9
Severity: Normal | Resolution:
Keywords: | Triage Stage: Unreviewed

Has patch: 0 | Needs documentation: 0
Needs tests: 0 | Patch needs improvement: 0

Easy pickings: 0 | UI/UX: 0
-------------------------------+--------------------------------------

Comment (by aaugustin):

Among the Western languages I'm familiar with, ä, ö and ü are most common
in German and this is indeed the proper way to transliterate them.

However it would look rather weird for the handful of French, Spanish and
Brazilian Portuguese words that include that letter.

I checked scandinavian languagues quickly and it looks like there's no
general rule. Per https://en.wikipedia.org/wiki/Finnish_orthography:

> The Germanic umlaut or convention of considering digraph ae equivalent
to ä, and oe equivalent to ö is inapplicable in Finnish.

--
Ticket URL: <https://code.djangoproject.com/ticket/26077#comment:3>

Django

unread,
Jan 13, 2016, 8:11:00 AM1/13/16
to django-...@googlegroups.com
#26077: Change latin map in urlify to correctly translate Umlauts
-------------------------------+--------------------------------------

Reporter: shredding | Owner: nobody
Type: Uncategorized | Status: new
Component: Uncategorized | Version: 1.9
Severity: Normal | Resolution:
Keywords: | Triage Stage: Unreviewed

Has patch: 0 | Needs documentation: 0
Needs tests: 0 | Patch needs improvement: 0

Easy pickings: 0 | UI/UX: 0
-------------------------------+--------------------------------------

Comment (by aaugustin):

It's a judgement call, but I'm -0 on this change. It would involve doing
something more complicated that sometimes doesn't make sense, rather than
doing something simple that isn't always optimal.

I won't stand in the way if we consider that German usage of ''umlauts''
is so dominant that we should ignore the edge cases in other languages.

--
Ticket URL: <https://code.djangoproject.com/ticket/26077#comment:4>

Django

unread,
Jan 13, 2016, 8:21:40 AM1/13/16
to django-...@googlegroups.com
#26077: Change latin map in urlify to correctly translate Umlauts
-------------------------------+--------------------------------------

Reporter: shredding | Owner: nobody
Type: Uncategorized | Status: new
Component: Uncategorized | Version: 1.9
Severity: Normal | Resolution:
Keywords: | Triage Stage: Unreviewed

Has patch: 0 | Needs documentation: 0
Needs tests: 0 | Patch needs improvement: 0

Easy pickings: 0 | UI/UX: 0
-------------------------------+--------------------------------------

Comment (by shredding):

I get the point.

Maybe URLify could expose an API that one could add / override MAPs? One
could then add some logic based on the settings.py to configure the
correct language?

It's used in Wagtail very heavily for slug generation and ATM i override
the entire URLify.

--
Ticket URL: <https://code.djangoproject.com/ticket/26077#comment:5>

Django

unread,
Jan 13, 2016, 8:24:14 AM1/13/16
to django-...@googlegroups.com
#26077: Change latin map in urlify to correctly translate Umlauts
-------------------------------+--------------------------------------

Reporter: shredding | Owner: nobody
Type: Uncategorized | Status: new
Component: Uncategorized | Version: 1.9
Severity: Normal | Resolution:
Keywords: | Triage Stage: Unreviewed

Has patch: 0 | Needs documentation: 0
Needs tests: 0 | Patch needs improvement: 0

Easy pickings: 0 | UI/UX: 0
-------------------------------+--------------------------------------

Comment (by aaugustin):

For better or worse, that's pretty much the expected solution if you need
something more tailored than Django's default utilities :-|

There's the same situation with the Python slugify function. Django has a
naive, four-line version that works fine for Western languages. If you
want something more advanced, there's https://github.com/mozilla/unicode-
slugify.

--
Ticket URL: <https://code.djangoproject.com/ticket/26077#comment:6>

Django

unread,
Jan 14, 2016, 7:55:29 PM1/14/16
to django-...@googlegroups.com
#26077: Change latin map in urlify to correctly translate Umlauts
-------------------------------------+-------------------------------------
Reporter: shredding | Owner: nobody
Type: | Status: closed
Cleanup/optimization |
Component: | Version: 1.9
Internationalization |
Severity: Normal | Resolution: wontfix
Keywords: | Triage Stage:
| Unreviewed

Has patch: 0 | Needs documentation: 0
Needs tests: 0 | Patch needs improvement: 0

Easy pickings: 0 | UI/UX: 0
-------------------------------------+-------------------------------------
Changes (by timgraham):

* status: new => closed
* resolution: => wontfix
* component: Uncategorized => Internationalization
* type: Uncategorized => Cleanup/optimization


Comment:

I guess the original proposal is a "wontfix" unless a discussion on the
DevelopersMailingList yields a different consensus.

--
Ticket URL: <https://code.djangoproject.com/ticket/26077#comment:7>

Reply all
Reply to author
Forward
0 new messages