Conversation
Codecov Report
@@ Coverage Diff @@
## master #572 +/- ##
=====================================
Coverage 94% 94%
=====================================
Files 4 4
Lines 434 434
Branches 77 77
=====================================
Hits 408 408
Misses 16 16
Partials 10 10Continue to review full report at Codecov.
|
Can you clarify? It should not be. We should add a test to verify the behavior before merging. |
|
+1 for this PR. Without this PR, django-taggit has serious performance issue in any non-English applications. django-taggit/taggit/models.py Lines 61 to 71 in 83fe619 Insert a new non-English tag to existing 10,000 tags, will cost 10,000 query. |
|
@lucemia thank you for pointing this out, I hadn't quite absorbed this fact when this had come up. To be honest I don't quite know what the value of "ascii-fying" everything for slugs is, it does feel a bit silly. So I think that having this setting, and having it be the new default (rationale: if you're using characters outside of ascii, it's very likely you find that important for your language). |
|
Of course after thinking about this a bit more I am reminded that slugification exists primarily for URLs and the like. For example if you have a URL scheme like I am going to try and dig up some ideas here for how to handle this. |
Unidecode translates non-English words, I have added an option to use the original language as a slug.
I tried to add a test, but adding non-English characters to the test code seemed to be a problem.