After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 596267 - division by zero when trying to load a timeline that starts with a still image
division by zero when trying to load a timeline that starts with a still image
Status: RESOLVED FIXED
Product: pitivi
Classification: Other
Component: General
Git
Other Linux
: Normal normal
: 0.13.4
Assigned To: Pitivi maintainers
Pitivi maintainers
Depends on:
Blocks:
 
 
Reported: 2009-09-25 04:21 UTC by Jean-François Fortin Tam
Modified: 2009-10-09 11:24 UTC
See Also:
GNOME target: ---
GNOME version: ---



Description Jean-François Fortin Tam 2009-09-25 04:21:39 UTC
I know... this is just borderline edge case crack, but I thought I'd report it anyway. I was loading a project and I accidentally clicked somewhere on the ruler, thus causing a seek, before there actually were clips to seek on the timeline. This is the result.

Problem is, I can't really reproduce it.


jeff@kusanagi:~/trunks/pitivi/pitivi$ bin/pitivi 

** (pitivi:27873): CRITICAL **: clearlooks_style_draw_focus: assertion `height >= -1' failed
Traceback (most recent call last):
  • File "pitivi/discoverer.py", line 404 in _busMessageEosCb
    self._finishAnalysis()
  • File "pitivi/discoverer.py", line 274 in _finishAnalysis
    if self._emitResult():
  • File "pitivi/discoverer.py", line 236 in _emitResult
    self._emitDone(factory)
  • File "pitivi/discoverer.py", line 196 in _emitDone
    self.emit("discovery-done", self.current_uri, factory)
  • File "pitivi/signalinterface.py", line 145 in emit
    *args, **kwargs)
  • File "pitivi/signalinterface.py", line 119 in emit
    res = cb(*ar, **kw)
  • File "pitivi/formatters/etree.py", line 703 in _discovererDiscoveryDoneCb
    self._finishLoadingProject(project)
  • File "pitivi/formatters/base.py", line 167 in _finishLoadingProject
    self.emit("new-project-loaded", self.project)
  • File "pitivi/signalinterface.py", line 145 in emit
    *args, **kwargs)
  • File "pitivi/signalinterface.py", line 119 in emit
    res = cb(*ar, **kw)
  • File "pitivi/projectmanager.py", line 185 in _formatterNewProjectLoaded
    self.emit("new-project-loaded", project)
  • File "pitivi/signalinterface.py", line 145 in emit
    *args, **kwargs)
  • File "pitivi/signalinterface.py", line 119 in emit
    res = cb(*ar, **kw)
  • File "pitivi/ui/mainwindow.py", line 688 in _projectManagerNewProjectLoadedCb
    self.project = project
  • File "pitivi/receiver.py", line 49 in __set__
    self.setter(instance)
  • File "pitivi/ui/mainwindow.py", line 905 in _setProject
    self.timeline.project = self.project
  • File "pitivi/receiver.py", line 49 in __set__
    self.setter(instance)
  • File "pitivi/ui/timeline.py", line 414 in _setProject
    self._canvas.timeline = self.timeline
  • File "pitivi/receiver.py", line 49 in __set__
    self.setter(instance)
  • File "pitivi/ui/timelinecanvas.py", line 332 in _set_timeline
    self._trackAdded(None, track)
  • File "pitivi/ui/timelinecanvas.py", line 339 in _trackAdded
    track = Track(self.app, track, self.timeline)
  • File "pitivi/ui/track.py", line 16 in __init__
    self.track = track
  • File "pitivi/receiver.py", line 49 in __set__
    self.setter(instance)
  • File "pitivi/ui/track.py", line 47 in _setTrack
    self._objectAdded(None, trackobj)
  • File "pitivi/ui/track.py", line 53 in _objectAdded
    w = TrackObject(self.app, track_object, self.track, self.timeline)
  • File "pitivi/ui/trackobject.py", line 243 in __init__
    self.content = Preview(element)
  • File "pitivi/ui/preview.py", line 49 in __init__
    self.element = element
  • File "pitivi/receiver.py", line 49 in __set__
    self.setter(instance)
  • File "pitivi/ui/preview.py", line 64 in _set_element
    self.previewer = previewer.get_preview_for_object(self.element)
  • File "pitivi/ui/previewer.py", line 130 in get_preview_for_object
    previewers[key] = StillImagePreviewer(factory, stream_)
  • File "pitivi/ui/previewer.py", line 359 in __init__
    self.frame_duration = (gst.SECOND * rate.denom) / rate.num
ZeroDivisionError: integer division or modulo by zero

Comment 1 Jean-François Fortin Tam 2009-09-25 16:54:54 UTC
Not so edge-case anymore; I can now reliably reproduce this by simply trying to load projects that have a png still at the beginning of their timeline (such as the pitivi 0.13.1 release screencast, or my "com1600 episode 1" project).
Comment 2 Alessandro Decina 2009-10-09 06:52:08 UTC
I think this was fixed by 

commit 93efaeb0fe6021bd0bba6b2ff1e1819f3d5d3be0
Author: Alessandro Decina <alessandro.d@gmail.com>
Date:   Wed Oct 7 16:25:56 2009 +0200

    Avoid exception generating thumbnails for streams having framerate 0/1

can you check?
Comment 3 Jean-François Fortin Tam 2009-10-09 11:24:54 UTC
Yes, it's fixed, thanks!