Skip to content

Commit

Permalink
Use float, else ceil() is meaningless
Browse files Browse the repository at this point in the history
  • Loading branch information
aagbsn committed Jan 2, 2013
1 parent 3e75dd2 commit 28861ec
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion ooni/inputunit.py
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ def __len__(self):
Returns the number of input units in the input unit factory.
"""
if not self.length:
self.length = ceil(sum(1 for _ in self._inputs)/self.inputUnitSize)
self.length = ceil(float(sum(1 for _ in self._inputs))/self.inputUnitSize)
return self.length

def next(self):
Expand Down

0 comments on commit 28861ec

Please sign in to comment.