carlxaeron / django-rosetta

Automatically exported from code.google.com/p/django-rosetta
MIT License
0 stars 0 forks source link

If a .po file has no entries you would get a divide by 0 entry #8

Closed GoogleCodeExporter closed 8 years ago

GoogleCodeExporter commented 8 years ago
What steps will reproduce the problem?
1. Create a .po file with no entries
2. Load the rosetta home page

What version of the product are you using? On what operating system?
SVN

Please provide any additional information below.
        if total == 0: return 100 # no divide by 0
Add that to line 522 and it prevents the problem.

Original issue reported on code.google.com by EdMenen...@gmail.com on 29 Apr 2008 at 2:10

GoogleCodeExporter commented 8 years ago
line 522 in /polib.py

Original comment by EdMenen...@gmail.com on 29 Apr 2008 at 2:13

GoogleCodeExporter commented 8 years ago
Thank you, well spotted!

Reported to polib: http://code.google.com/p/polib/issues/detail?id=5 and fixed 
locally

Original comment by mbonetti on 29 Apr 2008 at 2:27