FS#39714 - [pitivi] 0.93-3 Segmentation Fault on Startup

Attached to Project: Community Packages
Opened by Kevin Sarendranath (k.sarend) - Tuesday, 01 April 2014, 21:26 GMT
Last edited by Sergej Pupykin (sergej) - Monday, 17 November 2014, 10:49 GMT
Task Type Bug Report
Category Packages
Status Closed
Assigned To Sergej Pupykin (sergej)
Architecture All
Severity High
Priority Normal
Reported Version
Due in Version Undecided
Due Date Undecided
Percent Complete 100%
Votes 7
Private No

Details

Description:

The application doesn't run. It get hits with a segfault after stating the soft dependencies and crashes.

Here's the output from the terminal:

$ pitivi
Missing soft dependency:
- pycanberra not found on the system
-> enables sound notifications when rendering is complete
ERROR:root:Could not find any typelib for GnomeDesktop
Missing soft dependency:
- GnomeDesktop not found on the system
-> file thumbnails provided by GNOME's thumbnailers
Segmentation fault (core dumped)






Additional info:
package version : 0.93-3



Steps to reproduce:

1) Install pitivi and dependencies from repository.
2) Start pitivi in a terminal and crash occurs.
This task depends upon

Closed by  Sergej Pupykin (sergej)
Monday, 17 November 2014, 10:49 GMT
Reason for closing:  Fixed
Comment by Sergej Pupykin (sergej) - Wednesday, 02 April 2014, 09:31 GMT
Cannot reproduce.
Comment by Mathieu Duponchelle (Mathieu_Du) - Wednesday, 02 April 2014, 13:17 GMT
Hello, can you provide a stacktrace using "gdb --args python ./bin/pitivi" ?

Edit : you can also try lubosz's AUR package : https://aur.archlinux.org/packages/pitivi-git/
Comment by Kevin Sarendranath (k.sarend) - Wednesday, 02 April 2014, 20:23 GMT
Ran the script through the debugger and got a syntax error for the print statement within
the script.

$
...
Using host libthread_db library "/usr/lib/libthread_db.so.1".
File "/usr/bin/pitivi", line 82
print "Couldn't set locale."
^
SyntaxError: invalid syntax
[Inferior 1 (process 4176) exited with code 01]

I just realized that I've got muliple versions of python installed.
I've tried to run the script through each version but there still is the segfault.
Any ideas? Going to try the AUR package now.

Comment by Mathieu Duponchelle (Mathieu_Du) - Wednesday, 02 April 2014, 20:25 GMT
Hey, I don't have any ideas like that, btw we just pushed a port to python 3 amongst other things to master, bundles will be available by tomorrow.
Comment by Kevin Sarendranath (k.sarend) - Wednesday, 02 April 2014, 20:41 GMT
Thanks. Looking foward to testing the new bundles.
Will report back on the status.

Comment by Lubosz Sarnecki (lubosz) - Thursday, 03 April 2014, 23:03 GMT
Cannot reproduce with the binary package. Did you try to install the soft dependencies? GnomeDesktop in particular.

The SyntaxError: invalid syntax occurs because python2 code is ran in the python3 interpreter.
Comment by Kevin Sarendranath (k.sarend) - Saturday, 05 April 2014, 06:12 GMT
I ran pitivi through gdb again passing it through the python2.7 interpreter. Got
the segmentation fault flag pointing to an multithreaded issue.

$
...
Program received signal SIGSEGV, Segmentation fault.
0x00007ffff7808234 in pthread_mutex_lock () from /usr/lib/libpthread.so.0

Here's the backtrace of all the threads.




Comment by Lubosz Sarnecki (lubosz) - Saturday, 05 April 2014, 11:22 GMT
GDK apparently crashes when trying to access cursor information.
Which desktop environment do you use? Do you have any fancy cursor modifications?
In the end it crashes in libX11 / XrmQGetResource.
I see that you use r600, maybe driver related?
Is this reproducable with other Python / GTK software? Maybe gnome-music.
Comment by Kevin Sarendranath (k.sarend) - Saturday, 05 April 2014, 22:46 GMT
I tried installing pitivi on two seperate systems and got the same segfault and
backtrace. One using KDE and the other MATE. One using the r600 driver
and the other using nouveau. No special changes to either. I installed
gnome-music and it ran perfectly on both systems but both crashes
on pitivi.

Comment by Mikkel Oscar Lyderik (moscar) - Sunday, 06 April 2014, 12:35 GMT
I get the same error. I'm running i3wm and use intel. I have also tried gnome-music and that works fine.
Comment by Lubosz Sarnecki (lubosz) - Monday, 07 April 2014, 16:38 GMT
I am noticing that the bug occurs on non-GNOME installations. Maybe the soft dependency gnome-desktop is a hard one?
Do you have it installed? It starts for me, even without gnome-desktop.
I will try to run pitivi with mate or i3wm.
Comment by Mathieu Duponchelle (Mathieu_Du) - Monday, 07 April 2014, 16:43 GMT
gnome-desktop should not be a hard dependency, we need an abstraction for notifications badly (along with implementations for major DEs).
Comment by Mikkel Oscar Lyderik (moscar) - Monday, 07 April 2014, 16:54 GMT
Installing gnome-desktop doesn't make a difference for me, it still segfaults with gnome-desktop installed.
Comment by Lubosz Sarnecki (lubosz) - Monday, 07 April 2014, 18:55 GMT
I was able to reproduce the crash in XFCE. So the thesis the bug occurs in non-GNOME window managers is confirmed.
I was running GDM.
The crash occurs for me in cairo. Backtrace attached (current pitivi git version).
The crash even occurs in GNOME Classic.

So the bug should be worded:
Pitivi segfaults in Cairo when not run in GNOME Shell.
Comment by Kevin Sarendranath (k.sarend) - Tuesday, 08 April 2014, 01:25 GMT
So should this bug be passed upstream?
Comment by Lubosz Sarnecki (lubosz) - Tuesday, 08 April 2014, 17:06 GMT
I have filed this upstream bug:
https://bugzilla.gnome.org/show_bug.cgi?id=727851

Edit:

since the bundle works in arch, the dependencies have to be wrong.
I bet it's clutter-gst.

http://fundraiser.pitivi.org/download-bundles
Comment by GI Jack (GI_Jack) - Sunday, 20 April 2014, 00:12 GMT
I am able to reproduce the crash with XFCE and pitivi.

intresting note, it does not crash when run as root from a terminal

edit: I am guessing its a permissions issue with something
Comment by Lubosz Sarnecki (lubosz) - Sunday, 20 April 2014, 15:09 GMT
Maybe the user is part of another group when GNOME Shell is run?
Especially in the X11 part of things.

Anyway, it should not segfault when its a permissions issue.
I guess running as root just hides the symptoms of the problem.

Kubuntu is apparently encountering the same problem
https://bugs.launchpad.net/ubuntu/+source/pitivi/+bug/1307746
Comment by Enzzo (souenzzo) - Wednesday, 23 April 2014, 01:59 GMT
Here I have the same problem on user (A).
Oddly with user (B) I have no problem(user B is not root, hehe)
I also try to remove .config/piviti from user A and start again but didint work.
Shoud be same shared configuration with others gnome program.
[EDIT] Both LXDE
Comment by Justin Morgan (Baryon) - Saturday, 26 April 2014, 12:47 GMT
I also had this crash, using openbox, and for me it also happens when run as root.
Comment by Filipp Andjelo (scorp) - Friday, 09 May 2014, 16:47 GMT
Looks like an upstream error, because Ubuntu suffers the same issue:

https://bugs.launchpad.net/ubuntu/+source/pitivi/+bug/1307746
Comment by Lubosz Sarnecki (lubosz) - Friday, 09 May 2014, 17:56 GMT
@Baryon: interesting. did you try other users or window managers?

@scorp: the upstream bug url is https://bugzilla.gnome.org/show_bug.cgi?id=727851

the ubuntu bug is also referenced there.

contributions to the upstream bug discussion are welcome
Comment by Lubosz Sarnecki (lubosz) - Sunday, 11 May 2014, 10:44 GMT
It looks like this is not an upsteam bug.

The Fedora build Pitivi bundle does work.

Building with the gstreamer build system cerbero works on Arch and fixes the issue. You need the cerbero branch from thiblahute with my Arch patches:
https://github.com/lubosz/cerbero/tree/gi%2Bpitivi

Running my minimal crash python example works from the cerbero shell on Arch:
https://bugzilla.gnome.org/attachment.cgi?id=273831

$ ./cerbero-uninstalled shell
$ ./clutter-crash.py


This is a packaging issue and Ubuntu also has it.

Cerbero builds 10 boostrap packages and 89 for Pitivi. So the problem can only be in 99 Arch packages.
Comment by GI Jack (GI_Jack) - Thursday, 15 May 2014, 22:42 GMT
do you have a PKGBUILD in AUR?, or do you plan on writing one, if you don't want to do that yourself, let me know and I'll maintain the PKGBUILD.
Comment by Lubosz Sarnecki (lubosz) - Thursday, 15 May 2014, 22:55 GMT
@GI_Jack: I have a PKGBUILD for pitivi, it's pitivi-git, in sync with upstream. It works (R) only in gnome-shell currently.

The "fix" I mentioned by using cerbero, is building the whole GTK+ and GStreamer stack by "hand" without pacman. There is not much sense to package this :)

So the problem needs to be found in the Arch glib2 / gstreamer-1.0 stack. Didn't have much time comparing the builds yet.

My bug report for clutter-gst didn't find much love yet either: https://bugzilla.gnome.org/show_bug.cgi?id=729643
Comment by GI Jack (GI_Jack) - Thursday, 15 May 2014, 23:16 GMT
so what is the diffrence between cerbro and makepkg?
Comment by Kevin Sarendranath (k.sarend) - Friday, 16 May 2014, 03:19 GMT
Well this is weird.

I reinstalled pitivi on my Mate Arch Box and it works.
The only problem is that the GUI looks horrible but other than that, the program functions.

So this problem may be linked within clutter.
Comment by Lubosz Sarnecki (lubosz) - Friday, 16 May 2014, 06:33 GMT
@k.sarend: what did you change to make it running? Why do you think the problem is in clutter? It still crashes for me in GNOME Classic and XFCE after upgrading and rebuilding GStreamer+Pitivi

@GI_Jack: cerbero is a different build system. I does not use PKGBUILDs and the Arch build flags and methods from the ABS. Everything could be different there. You can build it on Arch though.
Comment by Kevin Sarendranath (k.sarend) - Friday, 16 May 2014, 20:12 GMT
Just the usual arch upgrade nothing special. Pitivi still fails on my kde box.

Clutter is just a speculation guess because it deals with the GUI.
It could be any other libraries that deals with the GUI since the program functionally works on my Mate box.
Comment by Lubosz Sarnecki (lubosz) - Saturday, 17 May 2014, 11:18 GMT
@k.sarend: Which display manager are you using? GDM? Pitivi crashes in mate for me.
Comment by Kevin Sarendranath (k.sarend) - Saturday, 17 May 2014, 20:01 GMT
LightDM.
Comment by George Farris (horga83) - Thursday, 05 June 2014, 22:23 GMT
I have also noticed that Pitivi will crash hard in Gnome-shell 3.12 when one tries to render, choose video and then advanced prefereneces on the video codec. Must ctrl-alt-backspace, login and kill the old leftover gnome-shell. This happens in Mate or GNOME 3.12. I have also tried pitivi-git from yaourt, same thing.

Happens everytime.
Comment by Lubosz Sarnecki (lubosz) - Friday, 06 June 2014, 10:56 GMT
@horga83: this is another problem and unrelated to this one. please file an upstream bug in GNOME bugzilla.
Comment by Faule Socke (socke) - Monday, 22 September 2014, 20:22 GMT
Same problem here using i3wm. It starts under openbox and even with weston using xwayland. In openbox I have displaying-issues (the timeline is not shown correctly).

My display manager is lxdm.

BTW: Cinelerra won't start with i3wm too (but works in openbox).
Comment by François (Spip) - Wednesday, 22 October 2014, 00:51 GMT
Hi,

I think I have a different backtrace:

Traceback (most recent call last):
File "/usr/bin/pitivi", line 137, in <module>
_run_pitivi()
File "/usr/bin/pitivi", line 124, in _run_pitivi
sys.exit(ptv.main(sys.argv))
File "/usr/lib/pitivi/python/pitivi/application.py", line 416, in main
ptv = StartupWizardGuiPitivi(debug=options.debug)
File "/usr/lib/pitivi/python/pitivi/application.py", line 362, in __init__
self.projectManager.newBlankProject(emission=False)
File "/usr/lib/pitivi/python/pitivi/project.py", line 429, in newBlankProject
self.emit("new-project-loaded", self.current_project, emission)
File "/usr/lib/pitivi/python/pitivi/utils/signal.py", line 212, in emit
*args, **kwargs)
File "/usr/lib/pitivi/python/pitivi/utils/signal.py", line 187, in emit
res = cb(*ar, **kw)
File "/usr/lib/pitivi/python/pitivi/timeline/timeline.py", line 1391, in _projectChangedCb
self.ruler.setProjectFrameRate(self._project.videorate)
File "/usr/lib/pitivi/python/pitivi/timeline/ruler.py", line 244, in setProjectFrameRate
self.ns_per_frame = float(1 / self.frame_rate) * Gst.SECOND
TypeError: unsupported operand type(s) for /: 'int' and 'NoneType'
Comment by Lubosz Sarnecki (lubosz) - Wednesday, 22 October 2014, 05:57 GMT
@François (Spip): Your gst-python is too old, if you have any at all.

Install this: https://www.archlinux.org/packages/community/x86_64/gst-python/
Otherwise you need a more recent version: https://aur.archlinux.org/packages/gst-python-git/

@All: This has been fixed upstream. Install the git package if you experience this issue. It will be in the next release.

https://aur.archlinux.org/packages/pitivi-git/
Comment by Jelle van der Waa (jelly) - Monday, 03 November 2014, 19:31 GMT Comment by Lubosz Sarnecki (lubosz) - Tuesday, 04 November 2014, 11:11 GMT
This issue has been fixed upstream with this commit https://git.gnome.org/browse/pitivi/commit/?id=39d4a56b07d9fe2ca4216e2bea4ed4d7da9950a1
It's in the new release.

Loading...