community icon indicating copy to clipboard operation
community copied to clipboard

Interactive Launcher Core Dump/Crash ipython

Open salibeh opened this issue 12 years ago • 4 comments

I have been using Interactive Launcher quite a bit lately. Yesterday, I encountered the following problem which I believe to be a bug. When I run the following code interactively using ipython, I get core dump and ipython quits. Note that the program runs fine using python2.7 main.py command. I would appreciate your help in resolving this issue. Emil PS. It appears that this happens every time run main.py launches a blank black window.


Here is the code:

from kivy.interactive import InteractiveLauncher
from kivy.app import App
from kivy.uix.button import Button
from kivy.uix.scrollview import ScrollView
from kivy.uix.gridlayout import GridLayout


class ScrollViewApp(App):
    def build(self):

        grid = GridLayout(rows=2, size_hint=(None,None))
        grid.bind(minimum_width=grid.setter('width'))

        for i in range(60):
            grid.add_widget(Button(text='#00' + str(i),size=(100,100), size_hint=(None,None)))

        scroll = ScrollView( size_hint=(1,1), do_scroll_x=True, do_scroll_y=False )
        scroll.add_widget(grid)

        return scroll

Here is ipython dialog and the crash/core dump (I am running ipython on Linux Ubuntu 12.04):

$ ipython 
Python 2.7.3 (default, Feb 27 2014, 19:58:35) 
Type "copyright", "credits" or "license" for more information.

IPython 1.2.1 -- An enhanced Interactive Python.
?         -> Introduction and overview of IPython's features.
%quickref -> Quick reference.
help      -> Python's own help system.
object?   -> Details about 'object', use 'object??' for extra details.

In [1]: run main.py
[INFO   ] Kivy v1.8.0
[INFO   ] [Logger      ] Record log in /home/checkout/.kivy/logs/kivy_14-08-02_35.txt
[INFO   ] [Factory     ] 157 symbols loaded
[DEBUG  ] [Cache       ] register <kv.lang> with limit=None, timeout=Nones
[DEBUG  ] [Cache       ] register <kv.image> with limit=None, timeout=60s
[DEBUG  ] [Cache       ] register <kv.atlas> with limit=None, timeout=Nones
[INFO   ] [Image       ] Providers: img_tex, img_dds, img_pygame, img_pil, img_gif 
[DEBUG  ] [Cache       ] register <kv.texture> with limit=1000, timeout=60s
[DEBUG  ] [Cache       ] register <kv.shader> with limit=1000, timeout=3600s
[INFO   ] [Text        ] Provider: pygame
[DEBUG  ] [Window      ] Ignored <egl_rpi> (import error)
[INFO   ] [Window      ] Provider: pygame(['window_egl_rpi'] ignored)
[WARNING] [WinPygame   ] Video: failed (multisamples=2)
[WARNING] [WinPygame   ] trying without antialiasing
[DEBUG  ] [Window      ] Display driver x11
[DEBUG  ] [Window      ] Actual window size: 800x600
[DEBUG  ] [Window      ] Actual color bits r8 g8 b8 a0
[DEBUG  ] [Window      ] Actual depth bits: 24
[DEBUG  ] [Window      ] Actual stencil bits: 8
[DEBUG  ] [Window      ] Actual multisampling samples: 0
[INFO   ] [GL          ] OpenGL version <2.1 Mesa 8.0.4>
[INFO   ] [GL          ] OpenGL vendor <VMware, Inc.>
[INFO   ] [GL          ] OpenGL renderer <Gallium 0.4 on llvmpipe (LLVM 0x300)>
[INFO   ] [GL          ] OpenGL parsed version: 2, 1
[INFO   ] [GL          ] Shading version <1.20>
[INFO   ] [GL          ] Texture max size <4096>
[INFO   ] [GL          ] Texture max units <16>
[DEBUG  ] [Shader      ] Fragment compiled successfully
[DEBUG  ] [Shader      ] Vertex compiled successfully
[DEBUG  ] [ImagePygame ] Load </usr/local/lib/python2.7/dist-packages/kivy/data/glsl/default.png>
[INFO   ] [Window      ] virtual keyboard not allowed, single mode, not docked   <<--------------  at this point I get a blank black window

In [2]: i=InteractiveLauncher(ScrollViewApp())

In [3]: i.run()

In [4]: [DEBUG  ] [App         ] Loading kv <./scrollview.kv>
[DEBUG  ] [App         ] kv <./scrollview.kv> not found
[INFO   ] [OSC         ] using <multiprocessing> for socket
[DEBUG  ] [Base        ] Create provider from mouse
[DEBUG  ] [Base        ] Create provider from probesysfs
[DEBUG  ] [ProbeSysfs  ] using probsysfs!
[INFO   ] [Base        ] Start application main loop
Fatal Python error: (pygame parachute) Segmentation Fault
Aborted (core dumped)

Want to back this issue? Post a bounty on it! We accept bounties via Bountysource.

salibeh avatar Aug 04 '14 13:08 salibeh

Same problem here. if I do MyApp().run, goes fine. but if I run the interactive launcher: launcher = InteractiveLauncher(MyApp()) launcher.run() segfaults like that (exact same message)

System info: [INFO ] Kivy v1.9.0-dev [INFO ] [Python ] v2.7.8 (default, Oct 20 2014, 15:05:19) [GCC 4.9.1]

Ubuntu 14.10 64bit

twoelz avatar Jan 10 '15 22:01 twoelz

ok, not the exact same problem, i get this when i run the script, I haven't tried ipython. but still, similar issue (same error)

twoelz avatar Jan 10 '15 22:01 twoelz

The interactive launcher has been deprecated in https://github.com/kivy/kivy/commit/3f83ed2a7b7d463d6b721b737b1adc0ec30ea7af.

dessant avatar Jan 31 '16 20:01 dessant

What is the alternative if it is deprecated?

kawing-chiu avatar Dec 25 '17 05:12 kawing-chiu