{{ "Hello Django" | truncatechars:10 }}
Django 2.1.x output: Hello D...
Django 2.2.x output: Hello Djan
But the doc match the first case
https://docs.djangoproject.com/en/2.2/ref/templates/builtins/#truncatechars
--
Ticket URL: <https://code.djangoproject.com/ticket/31037>
Django <https://code.djangoproject.com/>
The Web framework for perfectionists with deadlines.
* status: new => closed
* resolution: => invalid
Comment:
`truncatechars` now uses the real ellipsis character (…) instead of 3
dots, this is a
[https://docs.djangoproject.com/en/2.2/releases/2.2/#miscellaneous
documented] and expected change.
`{{ "Hello Django" | truncatechars:10 }}` returns `Hello Dja…` for me.
--
Ticket URL: <https://code.djangoproject.com/ticket/31037#comment:1>
Comment (by 老广):
Replying to [comment:1 felixxm]:
> `truncatechars` now uses the real ellipsis character (…) instead of 3
dots, this is a
[https://docs.djangoproject.com/en/2.2/releases/2.2/#miscellaneous
documented] and expected change.
>
> `{{ "Hello Django" | truncatechars:10 }}` returns `Hello Dja…` for me.
I found the bug, It's because the Django locale zh-hans Lost the ellipsis
> #, python-format
> msgctxt "String to return when truncating text"
> msgid "%(truncated_text)s…"
> msgstr "%(truncated_text)s"
--
Ticket URL: <https://code.djangoproject.com/ticket/31037#comment:2>
* status: closed => new
* resolution: invalid =>
--
Ticket URL: <https://code.djangoproject.com/ticket/31037#comment:3>
* status: new => closed
* resolution: => invalid
Comment:
Thanks for the report, however, translations are handled at
[https://docs.djangoproject.com/en/dev/internals/contributing/localizing/#translations.
Transifex] and not in this tracker.
--
Ticket URL: <https://code.djangoproject.com/ticket/31037#comment:4>