[Django] #28694: django.utils.text.slugify Django slugify correction

9 views
Skip to first unread message

Django

unread,
Oct 10, 2017, 12:57:17 PM10/10/17
to django-...@googlegroups.com
#28694: django.utils.text.slugify Django slugify correction
-------------------------------------+-------------------------------------
Reporter: Elinaldo | Owner: nobody
do Nascimento Monteiro |
Type: New | Status: new
feature |
Component: Utilities | Version: 1.11
Severity: Normal | Keywords: slugify, util
Triage Stage: | Has patch: 1
Unreviewed |
Needs documentation: 0 | Needs tests: 0
Patch needs improvement: 0 | Easy pickings: 0
UI/UX: 0 |
-------------------------------------+-------------------------------------
Bug generation slug

Example:

{{{
from django.utils import text
text.slugify("___This is a test ---")
output: ___this-is-a-test-
}}}

Improvement after correction

{{{
from django.utils import text
text.slugify("___This is a test ---")
output: this-is-a-test
}}}

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

Django

unread,
Oct 10, 2017, 12:59:28 PM10/10/17
to django-...@googlegroups.com
#28694: django.utils.text.slugify Django slugify correction
-------------------------------------+-------------------------------------
Reporter: Elinaldo do | Owner: nobody
Nascimento Monteiro |
Type: New feature | Status: new
Component: Utilities | Version: 1.11
Severity: Normal | Resolution:

Keywords: slugify, util | Triage Stage:
| Unreviewed
Has patch: 1 | Needs documentation: 0

Needs tests: 0 | Patch needs improvement: 0
Easy pickings: 0 | UI/UX: 0
-------------------------------------+-------------------------------------
Description changed by Elinaldo do Nascimento Monteiro:

Old description:

> Bug generation slug
>
> Example:
>
> {{{
> from django.utils import text
> text.slugify("___This is a test ---")
> output: ___this-is-a-test-
> }}}
>
> Improvement after correction
>
> {{{
> from django.utils import text
> text.slugify("___This is a test ---")
> output: this-is-a-test
> }}}

New description:

Bug generation slug

Example:

{{{
from django.utils import text
text.slugify("___This is a test ---")
output: ___this-is-a-test-
}}}

Improvement after correction

{{{
from django.utils import text
text.slugify("___This is a test ---")
output: this-is-a-test
}}}

Fix PR: https://github.com/django/django/pull/8733

--

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

Django

unread,
Oct 10, 2017, 1:09:29 PM10/10/17
to django-...@googlegroups.com
#28694: django.utils.text.slugify Django slugify correction
-------------------------------------+-------------------------------------
Reporter: Elinaldo do | Owner: Elinaldo
Nascimento Monteiro | do Nascimento Monteiro
Type: New feature | Status: assigned
Component: Utilities | Version: 1.11
Severity: Normal | Resolution:

Keywords: slugify, util | Triage Stage:
| Unreviewed
Has patch: 1 | Needs documentation: 0

Needs tests: 0 | Patch needs improvement: 0
Easy pickings: 0 | UI/UX: 0
-------------------------------------+-------------------------------------
Changes (by Elinaldo do Nascimento Monteiro):

* status: new => assigned
* owner: nobody => Elinaldo do Nascimento Monteiro


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

Django

unread,
Oct 10, 2017, 1:10:02 PM10/10/17
to django-...@googlegroups.com
#28694: django.utils.text.slugify Django slugify correction
-------------------------------------+-------------------------------------
Reporter: Elinaldo do | Owner: Elinaldo
Nascimento Monteiro | do Nascimento Monteiro
Type: New feature | Status: assigned
Component: Utilities | Version: master
Severity: Normal | Resolution:

Keywords: slugify, util | Triage Stage:
| Unreviewed
Has patch: 1 | Needs documentation: 0

Needs tests: 0 | Patch needs improvement: 0
Easy pickings: 0 | UI/UX: 0
-------------------------------------+-------------------------------------
Changes (by Elinaldo do Nascimento Monteiro):

* version: 1.11 => master


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

Django

unread,
Oct 10, 2017, 1:11:31 PM10/10/17
to django-...@googlegroups.com
#28694: django.utils.text.slugify Django slugify correction
-------------------------------------+-------------------------------------
Reporter: Elinaldo do | Owner: Elinaldo
Nascimento Monteiro | do Nascimento Monteiro
Type: New feature | Status: assigned
Component: Utilities | Version: master
Severity: Normal | Resolution:
Keywords: slugify, util | Triage Stage:
| Unreviewed
Has patch: 1 | Needs documentation: 0

Needs tests: 0 | Patch needs improvement: 0
Easy pickings: 0 | UI/UX: 0
-------------------------------------+-------------------------------------
Description changed by Elinaldo do Nascimento Monteiro:

Old description:

> Bug generation slug


>
> Example:
>
> {{{
> from django.utils import text
> text.slugify("___This is a test ---")
> output: ___this-is-a-test-
> }}}
>
> Improvement after correction
>
> {{{
> from django.utils import text
> text.slugify("___This is a test ---")
> output: this-is-a-test
> }}}
>

> Fix PR: https://github.com/django/django/pull/8733

New description:

Bug generation slug

Example:

{{{
from django.utils import text
text.slugify("___This is a test ---")
output: ___this-is-a-test-
}}}

Improvement after correction

{{{
from django.utils import text
text.slugify("___This is a test ---")
output: this-is-a-test
}}}

[https://github.com/django/django/pull/8733 PR]

--

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

Django

unread,
Oct 17, 2017, 9:23:37 AM10/17/17
to django-...@googlegroups.com
#28694: Make django.utils.text.slugify() remove redundant dashes and underscores

-------------------------------------+-------------------------------------
Reporter: Elinaldo do | Owner: Elinaldo
Nascimento Monteiro | do Nascimento Monteiro
Type: | Status: assigned
Cleanup/optimization |

Component: Utilities | Version: master
Severity: Normal | Resolution:
Keywords: slugify, util | Triage Stage: Accepted
Has patch: 1 | Needs documentation: 0

Needs tests: 0 | Patch needs improvement: 0
Easy pickings: 0 | UI/UX: 0
-------------------------------------+-------------------------------------
Changes (by Tim Graham):

* stage: Unreviewed => Accepted
* type: New feature => Cleanup/optimization


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

Django

unread,
Jan 10, 2018, 1:48:08 PM1/10/18
to django-...@googlegroups.com
#28694: Make django.utils.text.slugify() remove redundant dashes and underscores
-------------------------------------+-------------------------------------
Reporter: Elinaldo do | Owner: Elinaldo
Nascimento Monteiro | do Nascimento Monteiro
Type: | Status: assigned
Cleanup/optimization |
Component: Utilities | Version: master
Severity: Normal | Resolution:
Keywords: slugify, util | Triage Stage: Accepted
Has patch: 1 | Needs documentation: 0
Needs tests: 0 | Patch needs improvement: 1

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

* needs_better_patch: 0 => 1


Comment:

The current version of the patch converts all underscores to dashes which
(as discussed on the PR) isn't an obviously desired change. A discussion
is needed to see if there's consensus about that change.

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

Django

unread,
May 28, 2020, 6:06:24 AM5/28/20
to django-...@googlegroups.com
#28694: Make django.utils.text.slugify() remove redundant dashes and underscores
-------------------------------------+-------------------------------------
Reporter: Elinaldo do | Owner: David
Nascimento Monteiro | Smith

Type: | Status: assigned
Cleanup/optimization |
Component: Utilities | Version: master
Severity: Normal | Resolution:
Keywords: slugify, util | Triage Stage: Accepted
Has patch: 1 | Needs documentation: 0
Needs tests: 0 | Patch needs improvement: 1

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

* needs_better_patch: 0 => 1


--
Ticket URL: <https://code.djangoproject.com/ticket/28694#comment:8>

Django

unread,
May 29, 2020, 12:24:48 AM5/29/20
to django-...@googlegroups.com
#28694: Make django.utils.text.slugify() strip redundant dashes and underscores

-------------------------------------+-------------------------------------
Reporter: Elinaldo do | Owner: David
Nascimento Monteiro | Smith
Type: | Status: assigned
Cleanup/optimization |
Component: Utilities | Version: master
Severity: Normal | Resolution:
Keywords: slugify, util | Triage Stage: Ready for
| checkin
Has patch: 1 | Needs documentation: 0

Needs tests: 0 | Patch needs improvement: 0
Easy pickings: 0 | UI/UX: 0
-------------------------------------+-------------------------------------
Changes (by felixxm):

* needs_better_patch: 1 => 0
* stage: Accepted => Ready for checkin


--
Ticket URL: <https://code.djangoproject.com/ticket/28694#comment:9>

Django

unread,
May 29, 2020, 12:25:23 AM5/29/20
to django-...@googlegroups.com
#28694: Make django.utils.text.slugify() strip dashes and underscores

-------------------------------------+-------------------------------------
Reporter: Elinaldo do | Owner: David
Nascimento Monteiro | Smith
Type: | Status: assigned
Cleanup/optimization |
Component: Utilities | Version: master
Severity: Normal | Resolution:
Keywords: slugify, util | Triage Stage: Ready for
| checkin
Has patch: 1 | Needs documentation: 0

Needs tests: 0 | Patch needs improvement: 0
Easy pickings: 0 | UI/UX: 0
-------------------------------------+-------------------------------------
Changes (by felixxm):

* needs_better_patch: 1 => 0
* stage: Accepted => Ready for checkin

Django

unread,
May 29, 2020, 1:21:08 AM5/29/20
to django-...@googlegroups.com
#28694: Make django.utils.text.slugify() strip dashes and underscores
-------------------------------------+-------------------------------------
Reporter: Elinaldo do | Owner: David
Nascimento Monteiro | Smith
Type: | Status: closed

Cleanup/optimization |
Component: Utilities | Version: master
Severity: Normal | Resolution: fixed

Keywords: slugify, util | Triage Stage: Ready for
| checkin
Has patch: 1 | Needs documentation: 0

Needs tests: 0 | Patch needs improvement: 0
Easy pickings: 0 | UI/UX: 0
-------------------------------------+-------------------------------------
Changes (by Mariusz Felisiak <felisiak.mariusz@…>):

* status: assigned => closed
* resolution: => fixed


Comment:

In [changeset:"0382ecfe020b4c51b4c01e4e9a21892771e66941" 0382ecfe]:
{{{
#!CommitTicketReference repository=""
revision="0382ecfe020b4c51b4c01e4e9a21892771e66941"
Fixed #28694 -- Made django.utils.text.slugify() strip dashes and
underscores.
}}}

--
Ticket URL: <https://code.djangoproject.com/ticket/28694#comment:10>

Reply all
Reply to author
Forward
0 new messages