SimulaVR / Simula

Linux VR Desktop
MIT License
2.95k stars 87 forks source link

Input Randomly Crashes Simula #69

Closed georgewsinger closed 5 years ago

georgewsinger commented 5 years ago

Console dump:

xserver loaded
xfixes version: 5.0
created wm, root 668
onSurfaceCreated
onSurfaceCreated end
ERROR: find_by_type_and_id: Condition ' p_tracker_id == 0 ' is true. returned: __null
   At: servers/arvr_server.cpp:305.
handle_crash: Program crashed with signal 11
Dumping the backtrace. Please include this when reporting the bug on https://github.com/godotengine/godot/issues
[1] /lib/x86_64-linux-gnu/libc.so.6(+0x3ef20) [0x7f84fd7bdf20] (??:0)
[2] /home/george/Simula_/addons/godot-openvr/bin/x11/libgodot_openvr.so(+0x2b98) [0x7f84da2aab98] (??:0)
[3] godot() [0x21a5e85] (<artificial>:?)
[4] godot() [0x211931a] (<artificial>:?)
[5] godot() [0xcb39b4] (<artificial>:?)
[6] /lib/x86_64-linux-gnu/libpthread.so.0(+0x76db) [0x7f84fc01b6db] (??:0)
[7] /lib/x86_64-linux-gnu/libc.so.6(clone+0x3f) [0x7f84fd8a088f] (??:0)
-- END OF BACKTRACE --
(EE) 
Fatal server error:
(EE) failed to read Wayland events: Broken pipe
(EE) 
Aborted (core dumped)
Makefile:9: recipe for target 'run' failed
make[1]: *** [run] Error 134
make[1]: Leaving directory '/home/george/Simula_/addons/godot-haskell-plugin'

It is not clear if other things are required to reproduce this bug. So far it has happened while the Vive controller was pointed at a weston-terminal.

georgewsinger commented 5 years ago

This happened again with a different console output:

ERROR: find_by_type_and_id: Condition ' p_tracker_id == 0 ' is true. returned: __null
   At: servers/arvr_server.cpp:305.
XdndSelection owner: 8388627!
XdndSelection owner: 0!
ERROR: find_by_type_and_id: Condition ' p_tracker_id == 0 ' is true. returned: __null
   At: servers/arvr_server.cpp:305.
onSurfaceCreated
onSurfaceCreated end
ERROR: find_by_type_and_id: Condition ' p_tracker_id == 0 ' is true. returned: __null
   At: servers/arvr_server.cpp:305.
XdndSelection owner: 8388637!
handle_crash: Program crashed with signal 11
Dumping the backtrace. Please include this when reporting the bug on https://github.com/godotengine/godot/issues
[1] /lib/x86_64-linux-gnu/libc.so.6(+0x3ef20) [0x7f0bbdf3df20] (??:0)
handle_crash: Program crashed with signal 11
Dumping the backtrace. Please include this when reporting the bug on https://github.com/godotengine/godot/issues
[2] godot() [0xccdc87] (<artificial>:?)
[1] /lib/x86_64-linux-gnu/libc.so.6(+0x3ef20) [0x7f0bbdf3df20] (??:0)
[3] godot() [0xd445fb] (??:?)
[2] godot() [0xccdcdc] (<artificial>:?)
[4] godot() [0xa4a03e] (<artificial>:?)
[3] godot() [0xd44221] (??:?)
[5] godot() [0xa35b8c] (<artificial>:?)
[4] godot() [0xa3a460] (<artificial>:?)
[6] godot() [0xa35ae7] (<artificial>:?)
[5] godot() [0xa17ce2] (??:?)
[7] godot() [0xa35026] (<artificial>:?)
[6] godot() [0x902af5] (<artificial>:?)
[8] godot() [0xa88765] (<artificial>:?)
[7] godot() [0x9cefb8] (<artificial>:?)
[9] godot() [0xa3d2d5] (<artificial>:?)
[8] godot() [0x8f6616] (<artificial>:?)
[10] godot() [0x8ebd68] (<artificial>:?)
[9] godot() [0x192cbef] (<artificial>:?)
[11] godot() [0x104950b] (??:?)
[10] godot() [0x19418c5] (??:?)
[12] godot() [0x79c77d] (??:?)
[11] godot() [0xb06a24] (??:?)
[13] /lib/x86_64-linux-gnu/libc.so.6(__libc_start_main+0xe7) [0x7f0bbdf20b97] (??:0)
[12] godot() [0xa329d2] (??:?)
[14] godot() [0x7aa61e] (??:?)
-- END OF BACKTRACE --
(EE) 
Fatal server error:
(EE) failed to read Wayland events: Broken pipe
(EE) 
Aborted (core dumped)
Makefile:9: recipe for target 'run' failed
make[1]: *** [run] Error 134
make[1]: Leaving directory '/home/george/Simula_/addons/godot-haskell-plugin'
lboklin commented 5 years ago
ERROR: find_by_type_and_id: Condition ' p_tracker_id == 0 ' is true. returned: __null
   At: servers/arvr_server.cpp:305.

appears in both but also several times. I'm not sure what causes it but I don't think it's the reason for the crash.

XdndSelection owner: 8388637!

apparently is drag-and-drop related, so what produced this error must have been pointer click, thus it wasn't related to the grabbing.

This suggests the output is unfortunately not very informative.

lboklin commented 5 years ago

We really need to come up with a way to keep Simula up even if an application crashes. Having application crashes take Simula down with them is unacceptable.

lboklin commented 5 years ago

This appears to happen regardless of the type of input and is not limited to VR mode either. It happens (sooner or later) on

lboklin commented 5 years ago

I believe mouse input produces a crash that is different from the one caused by keyboard input. When click-spamming a window, eventually it will produce a crash that is somehow related to the Bullet physics engine used in Godot. Backtrace below:


Thread 1 "godot" received signal SIGABRT, Aborted.
__GI_raise (sig=sig@entry=6) at ../sysdeps/unix/sysv/linux/raise.c:51
51      ../sysdeps/unix/sysv/linux/raise.c: No such file or directory.
(gdb) bt
#0  __GI_raise (sig=sig@entry=6) at ../sysdeps/unix/sysv/linux/raise.c:51
#1  0x00007ffff5073801 in __GI_abort () at abort.c:79
#2  0x00007ffff5a668b7 in ?? () from /usr/lib/x86_64-linux-gnu/libstdc++.so.6
#3  0x00007ffff5a6ca06 in ?? () from /usr/lib/x86_64-linux-gnu/libstdc++.so.6
#4  0x00007ffff5a6ca41 in std::terminate() () from /usr/lib/x86_64-linux-gnu/libstdc++.so.6
#5  0x00007ffff5a6d80f in __cxa_pure_virtual () from /usr/lib/x86_64-linux-gnu/libstdc++.so.6
#6  0x000000000090ec70 in btConvexInternalShape::localGetSupportingVertex ()
    at thirdparty/bullet/BulletCollision/CollisionShapes/btConvexInternalShape.cpp:62
#7  0x00000000009262c4 in btSubsimplexConvexCast::calcTimeOfImpact ()
    at thirdparty/bullet/BulletCollision/NarrowPhaseCollision/btSubSimplexConvexCast.cpp:62
#8  0x00000000008fc41e in btCollisionWorld::rayTestSingleInternal ()
    at thirdparty/bullet/BulletCollision/CollisionDispatch/btCollisionWorld.cpp:324
#9  0x00000000008fcd84 in ProcessLeaf ()
    at thirdparty/bullet/BulletCollision/CollisionDispatch/btCollisionWorld.cpp:562
#10 btCollisionWorld::rayTestSingleInternal ()
    at thirdparty/bullet/BulletCollision/CollisionDispatch/btCollisionWorld.cpp:599
#11 0x00000000008fd46f in btCollisionWorld::rayTestSingle ()
    at thirdparty/bullet/BulletCollision/CollisionDispatch/btCollisionWorld.cpp:288
#12 0x0000000000977965 in btSoftRigidDynamicsWorld::rayTestSingle ()
    at thirdparty/bullet/BulletSoftBody/btSoftRigidDynamicsWorld.cpp:328
#13 0x00000000009794f6 in btSoftSingleRayCallback::process ()
    at thirdparty/bullet/BulletSoftBody/btSoftRigidDynamicsWorld.cpp:253
#14 0x00000000008ee774 in BroadphaseRayTester::Process ()
    at thirdparty/bullet/BulletCollision/BroadphaseCollision/btDbvtBroadphase.cpp:228
#15 btDbvt::rayTestInternal () at thirdparty/bullet/BulletCollision/BroadphaseCollision/btDbvt.h:1051
#16 btDbvtBroadphase::rayTest ()
    at thirdparty/bullet/BulletCollision/BroadphaseCollision/btDbvtBroadphase.cpp:253
#17 0x0000000000977246 in btSoftRigidDynamicsWorld::rayTest ()
    at thirdparty/bullet/BulletSoftBody/btSoftRigidDynamicsWorld.cpp:272
#18 0x00000000007a3e5a in BulletPhysicsDirectSpaceState::intersect_ray ()
    at modules/bullet/space_bullet.cpp:101
#19 0x00000000015f6d19 in Viewport::_notification () at scene/main/viewport.cpp:619
#20 0x00000000024155a4 in Object::notification () at core/object.cpp:955
#21 0x00000000015cedc8 in SceneTree::_notify_group_pause () at scene/main/scene_tree.cpp:966
#22 0x00000000015d1488 in SceneTree::iteration () at scene/main/scene_tree.cpp:473
#23 0x000000000045b5ab in Main::iteration () at main/main.cpp:1834
#24 0x0000000000443dd1 in OS_X11::run () at platform/x11/os_x11.cpp:2821
#25 0x0000000000435448 in main () at platform/x11/godot_x11.cpp:55

Edit: Tested with active soft world disabled in project settings (since there's a lot of soft body stuff in output) but the result is nearly identical barring the word Soft in the output.