Re: [Django] #16878: Improve the "intword" filter

2011-10-09 Thread Django
#16878: Improve the "intword" filter
--+
 Reporter:  crodjer   |Owner:  crodjer
 Type:  New feature   |   Status:  closed
Component:  contrib.humanize  |  Version:  SVN
 Severity:  Normal|   Resolution:  fixed
 Keywords:| Triage Stage:  Accepted
Has patch:  1 |  Needs documentation:  1
  Needs tests:  1 |  Patch needs improvement:  1
Easy pickings:  0 |UI/UX:  0
--+

Comment (by loewis):

 In [16950]:
 {{{
 #!CommitTicketReference repository="" revision="16950"
 Merged revisions
 
16743,16745,16747-16750,16752-16754,16756-16760,16770,16773-16800,16802-16804,16806,16808,16811,16813,16815,16817-16826,16829-16833,16835-16836,16838-16843,16845-16858,16860-16866,16868,16871-16877,16882-16890,16893-16947
 via svnmerge from
 https://code.djangoproject.com/svn/django/trunk

 
   r16743 | gabrielhurley | 2011-09-09 23:36:58 +0200 (Fr, 09 Sep 2011) | 2
 lines

   Fixed #16791 -- Updated a broken URL in the README file. Thanks to
 paulcwatts for the report and patch.
 
   r16745 | Alex | 2011-09-09 23:45:58 +0200 (Fr, 09 Sep 2011) | 1 line

   Switch to using explicit new-style division behavior, rather than
 relying on teh classic behavior.
 
   r16747 | SmileyChris | 2011-09-10 00:32:38 +0200 (Sa, 10 Sep 2011) | 1
 line

   Fix and test for cleaning a non-string value in a URLField
 
   r16748 | gabrielhurley | 2011-09-10 00:33:28 +0200 (Sa, 10 Sep 2011) | 2
 lines

   Fixed #16786 -- Minor cleanups in the memcached section of the caching
 topic guide. Thanks to jamesp for the report and patch.
 
   r16749 | jbronn | 2011-09-10 00:34:23 +0200 (Sa, 10 Sep 2011) | 1 line

   Fixed #16408 -- Fixed conversion of dates, and other problems with the
 SpatiaLite backend.
 
   r16750 | jbronn | 2011-09-10 00:47:18 +0200 (Sa, 10 Sep 2011) | 1 line

   Removed extra call to `syncdb` that slipped in with r16749.
 
   r16752 | SmileyChris | 2011-09-10 00:57:12 +0200 (Sa, 10 Sep 2011) | 1
 line

   Fixes #16664 -- URLField's to_python method fails with ValueError on
 some urls on python 2.7. Based on patch by zigzag.
 
   r16753 | russellm | 2011-09-10 01:02:33 +0200 (Sa, 10 Sep 2011) | 1 line

   Added two pointless query repeats to work around a known issue with
 MySQL that was causing failures in our test suite.
 
   r16754 | gabrielhurley | 2011-09-10 01:25:48 +0200 (Sa, 10 Sep 2011) | 2
 lines

   Fixed #16782 -- Corrected a broken cross-reference to the database
 engine setting in the tutorial. Thanks to mjumbewu for the report and
 patch.
 
   r16756 | kmtracey | 2011-09-10 02:05:48 +0200 (Sa, 10 Sep 2011) | 2
 lines

   Fixed #15722: ensure formsets evaluate to True even if they have no
 forms. Thanks mlavin.
 
   r16757 | jbronn | 2011-09-10 02:29:34 +0200 (Sa, 10 Sep 2011) | 1 line

   Fixed #13670 -- Comparisons with the spatial adapter won't blow up in
 some corner cases.  Thanks, milosu for the bug report and jpaulett for the
 patch.
 
   r16758 | russellm | 2011-09-10 02:46:38 +0200 (Sa, 10 Sep 2011) | 1 line

   Added protection against spoofing of X_FORWARDED_HOST headers. A
 security announcement will be made shortly.
 
   r16759 | russellm | 2011-09-10 02:46:48 +0200 (Sa, 10 Sep 2011) | 1 line

   Corrected an issue which could allow attackers to manipulate session
 data using the cache. A security announcement will be made shortly.
 
   r16760 | russellm | 2011-09-10 02:47:00 +0200 (Sa, 10 Sep 2011) | 1 line

   Altered the behavior of URLField to avoid a potential DOS vector, and to
 avoid potential leakage of local filesystem data. A security announcement
 will be made shortly.
 
   r16770 | Alex | 2011-09-10 03:53:56 +0200 (Sa, 10 Sep 2011) | 1 line

   Make ``Formset.__getitem__`` O(1), rather than O(n).  If you override
 ``__iter__`` you now need to also override ``__getitem__`` for consistant
 behavior.  Thanks to Carl and Russ for the review.
 
   r16773 | Alex | 2011-09-10 04:42:05 +0200 (Sa, 10 Sep 2011) | 1 line

   Fixed #11404.  Added ``FormSet.has_changed``, for consistancy with
 ``Form.has_changed``. Thanks to michelts for the patch.
 
   r16774 | Alex | 2011-09-10 04:52:37 +0200 (Sa, 10 Sep 2011) | 1 line

   Fixed #16793. Added more cross referencing to the load tag's
 documentation.  Thanks to bluejeansummer for the patch.
 
   r16775 | jbronn | 2011-09-10 05:04:30 +0200 (Sa, 10 Sep 2011) | 1 line

   Fixed #16790 -- Modified the geographic admin to work after r16594.
 Thanks, jdiego, for the bug report and patch.
 
   r16776 | carljm | 2011-09-10 05:26:13 +0200 (Sa, 10 Sep 2011) | 1 line

   

Re: [Django] #16878: Improve the "intword" filter

2011-09-24 Thread Django
#16878: Improve the "intword" filter
---+--
   Reporter:  crodjer  |  Owner:  crodjer
   Type:  New feature  | Status:  closed
  Milestone:   |  Component:  contrib.humanize
Version:  SVN  |   Severity:  Normal
 Resolution:  fixed|   Keywords:
   Triage Stage:  Accepted |  Has patch:  1
Needs documentation:  1|Needs tests:  1
Patch needs improvement:  1|  Easy pickings:  0
  UI/UX:  0|
---+--
Changes (by julien):

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


Comment:

 Fixed in r16900, thanks! :)

-- 
Ticket URL: 
Django 
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To post to this group, send email to django-updates@googlegroups.com.
To unsubscribe from this group, send email to 
django-updates+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/django-updates?hl=en.



Re: [Django] #16878: Improve the "intword" filter

2011-09-24 Thread Django
#16878: Improve the "intword" filter
---+--
   Reporter:  crodjer  |  Owner:  crodjer
   Type:  New feature  | Status:  reopened
  Milestone:   |  Component:  contrib.humanize
Version:  SVN  |   Severity:  Normal
 Resolution:   |   Keywords:
   Triage Stage:  Accepted |  Has patch:  1
Needs documentation:  1|Needs tests:  1
Patch needs improvement:  1|  Easy pickings:  0
  UI/UX:  0|
---+--
Changes (by jezdez):

 * status:  closed => reopened
 * resolution:  worksforme =>


Comment:

 So yeah, after having tested this on Python 2.5 I see the error after all:

 {{{
 Creating test database for alias 'default'...
 Creating test database for alias 'other'...
 ..F.F.
 ==
 FAIL: test_i18n_intword (django.contrib.humanize.tests.HumanizeTests)
 --
 Traceback (most recent call last):
   File "/Users/jezdez/Code/git/django/django/contrib/humanize/tests.py",
 line 82, in test_i18n_intword
 self.humanize_tester(test_list, result_list, 'intword')
   File "/Users/jezdez/Code/git/django/django/contrib/humanize/tests.py",
 line 22, in humanize_tester
 msg="%s test failed, produced '%s', should've produced '%s'" %
 (method, rendered, result))
 AssertionError: u'0,0 decillion' != u'1,0 Million' : intword test failed,
 produced '0,0 decillion', should've produced '1,0 Million'

 ==
 FAIL: test_intword (django.contrib.humanize.tests.HumanizeTests)
 --
 Traceback (most recent call last):
   File "/Users/jezdez/Code/git/django/django/contrib/humanize/tests.py",
 line 64, in test_intword
 self.humanize_tester(test_list, result_list, 'intword')
   File "/Users/jezdez/Code/git/django/django/contrib/humanize/tests.py",
 line 22, in humanize_tester
 msg="%s test failed, produced '%s', should've produced '%s'" %
 (method, rendered, result))
 AssertionError: u'0.0 decillion' != u'1.0 million' : intword test failed,
 produced '0.0 decillion', should've produced '1.0 million'

 --
 Ran 10 tests in 0.043s

 FAILED (failures=2)
 }}}

 Re-re-opening :)

-- 
Ticket URL: 
Django 
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To post to this group, send email to django-updates@googlegroups.com.
To unsubscribe from this group, send email to 
django-updates+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/django-updates?hl=en.



Re: [Django] #16878: Improve the "intword" filter

2011-09-24 Thread Django
#16878: Improve the "intword" filter
---+--
   Reporter:  crodjer  |  Owner:  crodjer
   Type:  New feature  | Status:  closed
  Milestone:   |  Component:  contrib.humanize
Version:  SVN  |   Severity:  Normal
 Resolution:  worksforme   |   Keywords:
   Triage Stage:  Accepted |  Has patch:  1
Needs documentation:  1|Needs tests:  1
Patch needs improvement:  1|  Easy pickings:  0
  UI/UX:  0|
---+--
Changes (by jezdez):

 * status:  reopened => closed
 * resolution:   => worksforme


Comment:

 I don't see how this patch would fix the error we see on the buildbout:
 
http://ci.djangoproject.com/job/Django/296/database=sqlite3,python=python2.6/console

 I think this is related to stale files on the buildbot due to moving the
 test directory, not the order. At least I can't reproduce a situation in
 which the order (as tried to be fixed by @julienphalip's patch) would be
 of importance to the intword filter.

-- 
Ticket URL: 
Django 
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To post to this group, send email to django-updates@googlegroups.com.
To unsubscribe from this group, send email to 
django-updates+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/django-updates?hl=en.



Re: [Django] #16878: Improve the "intword" filter

2011-09-23 Thread Django
#16878: Improve the "intword" filter
---+--
   Reporter:  crodjer  |  Owner:  crodjer
   Type:  New feature  | Status:  reopened
  Milestone:   |  Component:  contrib.humanize
Version:  SVN  |   Severity:  Normal
 Resolution:   |   Keywords:
   Triage Stage:  Accepted |  Has patch:  1
Needs documentation:  1|Needs tests:  1
Patch needs improvement:  1|  Easy pickings:  0
  UI/UX:  0|
---+--
Changes (by julien):

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


Comment:

 The `humanize` tests are failing, most likely because
 `intword_converters.items()` returns the items in the wrong order. The
 attached patch makes used of `SortedDict` to enforce a deterministic
 order.

-- 
Ticket URL: 
Django 
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To post to this group, send email to django-updates@googlegroups.com.
To unsubscribe from this group, send email to 
django-updates+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/django-updates?hl=en.



Re: [Django] #16878: Improve the "intword" filter

2011-09-23 Thread Django
#16878: Improve the "intword" filter
---+--
   Reporter:  crodjer  |  Owner:  crodjer
   Type:  New feature  | Status:  closed
  Milestone:   |  Component:  contrib.humanize
Version:  SVN  |   Severity:  Normal
 Resolution:  fixed|   Keywords:
   Triage Stage:  Accepted |  Has patch:  1
Needs documentation:  1|Needs tests:  1
Patch needs improvement:  1|  Easy pickings:  0
  UI/UX:  0|
---+--
Changes (by jezdez):

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


Comment:

 In [16897]:
 {{{
 #!CommitTicketReference repository="" revision="16897"
 Fixed #16878 -- Improved intword filter to support numbers up to decillion
 and googol. Thanks to crodjer for the initial patch.
 }}}

-- 
Ticket URL: 
Django 
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To post to this group, send email to django-updates@googlegroups.com.
To unsubscribe from this group, send email to 
django-updates+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/django-updates?hl=en.



Re: [Django] #16878: Improve the "intword" filter

2011-09-23 Thread Django
#16878: Improve the "intword" filter
---+--
   Reporter:  crodjer  |  Owner:  crodjer
   Type:  New feature  | Status:  new
  Milestone:   |  Component:  contrib.humanize
Version:  SVN  |   Severity:  Normal
 Resolution:   |   Keywords:
   Triage Stage:  Accepted |  Has patch:  1
Needs documentation:  1|Needs tests:  1
Patch needs improvement:  1|  Easy pickings:  0
  UI/UX:  0|
---+--

Comment (by crodjer):

 Replying to [comment:8 jezdez]:
 >
 > That's not enough, the string needs to be one and only one string to be
 translated, not something that consists of two separate strings.
 >
 > > In the commit, I have manually edited only one language translation
 file (de) for use in the i18n regressions tests. Rest are all
 autogenerated.
 >
 > Right, please revert the changes done to the other po files. You can
 prevent updating all those files by passing the specific language you want
 makemessages to update with the `-l` option.

 Updated the code according to your suggestions. Now no changes in existing
 translations would be needed, just additions maybe for largeer number
 strings.

-- 
Ticket URL: 
Django 
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To post to this group, send email to django-updates@googlegroups.com.
To unsubscribe from this group, send email to 
django-updates+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/django-updates?hl=en.



Re: [Django] #16878: Improve the "intword" filter

2011-09-22 Thread Django
#16878: Improve the "intword" filter
---+--
   Reporter:  crodjer  |  Owner:  crodjer
   Type:  New feature  | Status:  new
  Milestone:   |  Component:  contrib.humanize
Version:  SVN  |   Severity:  Normal
 Resolution:   |   Keywords:
   Triage Stage:  Accepted |  Has patch:  1
Needs documentation:  1|Needs tests:  1
Patch needs improvement:  1|  Easy pickings:  0
  UI/UX:  0|
---+--

Comment (by jezdez):

 Replying to [comment:7 crodjer]:
 > To take care of the " " issue exactly, I have kept
 another two ungettext calls '%(value)s %(suffix)s', '%(value)s %(suffix)s'
 (lines 98,99) which generate a translation for specifying that in the
 translation files. So apart from the definations of large number words,
 the format can also be specified with it.

 That's not enough, the string needs to be one and only one string to be
 translated, not something that consists of two separate strings.

 > In the commit, I have manually edited only one language translation file
 (de) for use in the i18n regressions tests. Rest are all autogenerated.

 Right, please revert the changes done to the other po files. You can
 prevent updating all those files by passing the specific language you want
 makemessages to update with the `-l` option.

-- 
Ticket URL: 
Django 
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To post to this group, send email to django-updates@googlegroups.com.
To unsubscribe from this group, send email to 
django-updates+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/django-updates?hl=en.



Re: [Django] #16878: Improve the "intword" filter

2011-09-22 Thread Django
#16878: Improve the "intword" filter
---+--
   Reporter:  crodjer  |  Owner:  crodjer
   Type:  New feature  | Status:  new
  Milestone:   |  Component:  contrib.humanize
Version:  SVN  |   Severity:  Normal
 Resolution:   |   Keywords:
   Triage Stage:  Accepted |  Has patch:  1
Needs documentation:  1|Needs tests:  1
Patch needs improvement:  1|  Easy pickings:  0
  UI/UX:  0|
---+--

Comment (by crodjer):

 To take care of the " " issue exactly, I have kept
 another two ungettext calls '%(value)s %(suffix)s', '%(value)s %(suffix)s'
 (lines 98,99) which generate a translation for specifying that in the
 translation files. So apart from the definations of large number words,
 the format can also be specified with it.

 In the commit, I have manually edited only one language translation file
 (de) for use in the i18n regressions tests. Rest are all autogenerated.

-- 
Ticket URL: 
Django 
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To post to this group, send email to django-updates@googlegroups.com.
To unsubscribe from this group, send email to 
django-updates+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/django-updates?hl=en.



Re: [Django] #16878: Improve the "intword" filter

2011-09-22 Thread Django
#16878: Improve the "intword" filter
---+--
   Reporter:  crodjer  |  Owner:  crodjer
   Type:  New feature  | Status:  new
  Milestone:   |  Component:  contrib.humanize
Version:  SVN  |   Severity:  Normal
 Resolution:   |   Keywords:
   Triage Stage:  Accepted |  Has patch:  1
Needs documentation:  1|Needs tests:  1
Patch needs improvement:  1|  Easy pickings:  0
  UI/UX:  0|
---+--

Comment (by jezdez):

 The patch still needs improvement:

 - The `ungettext` call shouldn't only contain the number word (e.g.
 `ungettext('billion', 'billion', n)`) but also a placeholder for the value
 (e.g.`ungettext('%(value)s billion', '%(value)s billion', n)`. The reason
 is simple: there are languages which don't follow the same order of words
 of " ". That's why It should be left to the translator
 to decide it.

 - You don't have to update all the po files manually, updating the base
 translation file (the English po file) is enough since that's what the
 Django project on transifex.net will pickup automatically.

-- 
Ticket URL: 
Django 
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To post to this group, send email to django-updates@googlegroups.com.
To unsubscribe from this group, send email to 
django-updates+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/django-updates?hl=en.



Re: [Django] #16878: Improve the "intword" filter

2011-09-20 Thread Django
#16878: Improve the "intword" filter
---+--
   Reporter:  crodjer  |  Owner:  crodjer
   Type:  New feature  | Status:  new
  Milestone:   |  Component:  contrib.humanize
Version:  SVN  |   Severity:  Normal
 Resolution:   |   Keywords:
   Triage Stage:  Accepted |  Has patch:  1
Needs documentation:  1|Needs tests:  1
Patch needs improvement:  1|  Easy pickings:  0
  UI/UX:  0|
---+--

Comment (by crodjer):

 Updated the code to user lamda functions for each large number from the
 list.[[BR]]
 Commit (on gihub):
 
[d81c5566e](https://github.com/crodjer/django/commit/d81c5566e28dba8330798bed7f8f4ce83001c738)

-- 
Ticket URL: 
Django 
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To post to this group, send email to django-updates@googlegroups.com.
To unsubscribe from this group, send email to 
django-updates+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/django-updates?hl=en.



Re: [Django] #16878: Improve the "intword" filter

2011-09-20 Thread Django
#16878: Improve the "intword" filter
---+--
   Reporter:  crodjer  |  Owner:  crodjer
   Type:  New feature  | Status:  new
  Milestone:   |  Component:  contrib.humanize
Version:  SVN  |   Severity:  Normal
 Resolution:   |   Keywords:
   Triage Stage:  Accepted |  Has patch:  1
Needs documentation:  1|Needs tests:  1
Patch needs improvement:  1|  Easy pickings:  0
  UI/UX:  0|
---+--
Changes (by jezdez):

 * type:  Cleanup/optimization => New feature


-- 
Ticket URL: 
Django 
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To post to this group, send email to django-updates@googlegroups.com.
To unsubscribe from this group, send email to 
django-updates+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/django-updates?hl=en.



Re: [Django] #16878: Improve the "intword" filter

2011-09-20 Thread Django
#16878: Improve the "intword" filter
-+-
   Reporter:  crodjer|  Owner:  crodjer
   Type: | Status:  new
  Cleanup/optimization   |  Component:  contrib.humanize
  Milestone: |   Severity:  Normal
Version:  SVN|   Keywords:
 Resolution: |  Has patch:  1
   Triage Stage:  Accepted   |Needs tests:  1
Needs documentation:  1  |  Easy pickings:  0
Patch needs improvement:  1  |
  UI/UX:  0  |
-+-
Changes (by jezdez):

 * needs_docs:  0 => 1
 * needs_tests:  0 => 1


Comment:

 The proposed patch (on Github) is incorrect in a number of ways:

 1. even if they are very big numbers, they still have a singular and a
 plural in some languages (e.g, "Septillion" and "Septillionen" in German)

 2. it doesn't actually mark the number words for translation since you
 using string concatenation to create the string to passed to `ungettext`

 3. this needs more thorough tests with another (non-English) language

-- 
Ticket URL: 
Django 
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To post to this group, send email to django-updates@googlegroups.com.
To unsubscribe from this group, send email to 
django-updates+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/django-updates?hl=en.



Re: [Django] #16878: Improve the "intword" filter

2011-09-19 Thread Django
#16878: Improve the "intword" filter
-+-
   Reporter:  crodjer|  Owner:  crodjer
   Type: | Status:  new
  Cleanup/optimization   |  Component:  contrib.humanize
  Milestone: |   Severity:  Normal
Version:  SVN|   Keywords:
 Resolution: |  Has patch:  1
   Triage Stage:  Accepted   |Needs tests:  0
Needs documentation:  0  |  Easy pickings:  0
Patch needs improvement:  1  |
  UI/UX:  0  |
-+-

Comment (by crodjer):

 I understand this is not of much importance. I was going through the code
 and found this so wrote a quick patch.

 I have fixed the code to pass the translation regression tests and updated
 the tests to cover some new larger numbers. Also to make it look cleaner
 updated the code so that in the conversions list the exponent to 10 is
 specified instead of numbers with large number of zeroes.

-- 
Ticket URL: 
Django 
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To post to this group, send email to django-updates@googlegroups.com.
To unsubscribe from this group, send email to 
django-updates+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/django-updates?hl=en.



Re: [Django] #16878: Improve the "intword" filter

2011-09-19 Thread Django
#16878: Improve the "intword" filter
-+-
   Reporter:  crodjer|  Owner:  crodjer
   Type: | Status:  new
  Cleanup/optimization   |  Component:  contrib.humanize
  Milestone: |   Severity:  Normal
Version:  SVN|   Keywords:
 Resolution: |  Has patch:  1
   Triage Stage:  Accepted   |Needs tests:  0
Needs documentation:  0  |  Easy pickings:  0
Patch needs improvement:  1  |
  UI/UX:  0  |
-+-
Changes (by carljm):

 * needs_better_patch:   => 1
 * version:  1.3 => SVN
 * stage:  Unreviewed => Accepted
 * needs_tests:   => 0
 * needs_docs:   => 0


Comment:

 Accepting, though I think this is pretty low priority.

 There should be tests added to cover the newly-supported bigger numbers,
 but they should go in `regressiontests/humanize/tests.py` with the
 existing intword tests.

-- 
Ticket URL: 
Django 
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To post to this group, send email to django-updates@googlegroups.com.
To unsubscribe from this group, send email to 
django-updates+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/django-updates?hl=en.



[Django] #16878: Improve the "intword" filter

2011-09-19 Thread Django
#16878: Improve the "intword" filter
--+--
 Reporter:  crodjer   |  Owner:  crodjer
 Type:  Cleanup/optimization  | Status:  new
Milestone:|  Component:  contrib.humanize
  Version:  1.3   |   Severity:  Normal
 Keywords:|   Triage Stage:  Unreviewed
Has patch:  1 |  Easy pickings:  0
UI/UX:  0 |
--+--
 The current code for intword function is repetitive. For each name,
 same code block is re-written.

 The patch from [https://github.com/django/django/pull/48 this] pull
 request,
 makes the code more DRY and also allowes the use words which
 represent much larger numbers then trillion. In the code, if the lots of
 zeroes don't look too good, they can be replaced to exponent form and used
 as {{{10**n}}}. I used zeroes thinking that might save some compution. The
 test in other commit can be neglected if not needed.

-- 
Ticket URL: 
Django 
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To post to this group, send email to django-updates@googlegroups.com.
To unsubscribe from this group, send email to 
django-updates+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/django-updates?hl=en.