urlize filter does not handle trailing 'dot-dot-dot' correctly

27 views
Skip to first unread message

wi...@agolo.com

unread,
Nov 4, 2014, 11:13:33 AM11/4/14
to django...@googlegroups.com
Hi, new guy around here.

I am an engineer for a startup (www.agolo.com, check us out :P). We work heavily with twitter content, and i've discovered that the urlize template tag/filter does not handle trailing 'dot-dot-dot' (which is common in tweet content due to all the truncation and whatnot) correctly, since it assume that the url can only have 1 trailing punctuation character. should I open a pull request for this, or was this problem raised before?

regards,
Will

Aliane Abdelouahab

unread,
Nov 4, 2014, 6:12:27 PM11/4/14
to django...@googlegroups.com
you can base64 encode it, and decode it after (as a temporary solution)

Russell Keith-Magee

unread,
Nov 4, 2014, 6:18:06 PM11/4/14
to Django Users
Hi Will,

If you want to know if a problem has been reported before, the place to start is the ticket tracker: here's a search of all tickets that mention urlize:


From a quick scan, I can't spot anything related to ellipses; there's a recent ticket related to exclamation marks, though:


which would suggest that there is a known subclass of punctuation-related issues. If you've got a case that reliably breaks (which it sounds like you do), open a ticket describing the exact problem, and if you're really adventurous, try your hand at a patch and pull request. The full guidelines for contributing can be found here:


Yours,
Russ Magee %-)


--
You received this message because you are subscribed to the Google Groups "Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to django-users...@googlegroups.com.
To post to this group, send email to django...@googlegroups.com.
Visit this group at http://groups.google.com/group/django-users.
To view this discussion on the web visit https://groups.google.com/d/msgid/django-users/85845fcb-606a-40b2-8df1-97afc6d4f1fd%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply all
Reply to author
Forward
0 new messages