Trim causes ZeroDivisionError
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
| Jokosher |
High
|
Laszlo Pandy |
Bug Description
1. Load an audio file.
2. hold shift key make selection for trimming
3. Select Trim Icon
Trim does not occur but produces the following in the terminal:
Traceback (most recent call last):
File "/home/
self.
File "/home/
result = func(funcSelf, *args, **kwargs)
File "/home/
leftSplit = self.split_
File "/home/
e._
File "/home/
self.
File "/home/
oneSecondIn
ZeroDivisionError: integer division or modulo by zero
Using r1284.
Changed in jokosher: | |
assignee: | nobody → laszlok2 |
importance: | Undecided → High |
status: | Unconfirmed → Confirmed |
David Corrales (davidcorrales) wrote : | #1 |
using r1306
still occuring for me.
Laszlo Pandy (laszlok) wrote : | #3 |
No it is not fixed. It happens if you try and cut really close to either edge of an event. The piece that it cuts off will have a duration of 0, and that causes the traceback. To fix this, we need an if statement checking if the duration is zero. If it is, we don't chop anything off that side. However when undoing trim, Jokosher expects to replace one clip on either side. If one of those clips was not created because if this if statement, Jokosher will crash when not finding the second clip to put back. The proper way to solve all these issues to is make trim use the atomic undo action system, which means it can specify how many actions it wishes to perform, and only those will get undone. This bug is assigned to me and I will fix it as soon as I get a chance.
Changed in jokosher: | |
status: | Fix Committed → Fix Released |
Is this bug fixed now? I can't get to reproduce it here.
Can anyone provide a good test case audio file?