【发布时间】:2021-06-16 03:47:42
【问题描述】:
这是一个奇怪的问题 - 我只是想在 Fedora 32 上组合一个简单的 wxpython TaskBarIcon,但它会引发段错误和 BadImplementation 错误。我见过一些类似的线程,但没有一个可以解决我的问题。这是发行版中的 Xorg/Wayland 打包错误,还是我缺少一些基本的东西?
msg=NotificationMessage('test', 'test')
msg.Show(timeout=wx.adv.NotificationMessage.Timeout_Auto)
在原本完全健康的 TaskBarIcon 应用程序中的这个简单代码会产生 SIGSEGV 或以下崩溃:
(livewebcam.py:906900): Gdk-ERROR **: 17:05:27.719: The program 'test.py' received an X Window System error.
This probably reflects a bug in the program.
The error was 'BadImplementation (server does not implement operation)'.
(Details: serial 838 error_code 17 request_code 20 (core protocol) minor_code 0)
(Note to programmers: normally, X errors are reported asynchronously;
that is, you will receive the error a while after causing it.
To debug your program, run it with the GDK_SYNCHRONIZE environment
variable to change this behavior. You can then get a meaningful
backtrace from your debugger if you break on the gdk_x_error() function.)
以下已安装版本。 KDE 在 Xorg(不是 Wayland)上旋转。
Installed Packages
Name : xorg-x11-server-Xorg
Version : 1.20.10
Release : 1.fc32
Architecture : x86_64
Size : 3.8 M
Source : xorg-x11-server-1.20.10-1.fc32.src.rpm
python-wxpython4-doc.noarch 4.0.7-5.fc32
python3-wxpython4.x86_64 4.0.7-5.fc32
python3-wxpython4-media.x86_64 4.0.7-5.fc32
python3-wxpython4-webview.x86_64 4.0.7-5.fc32
wxBase3.x86_64 3.0.4-13.fc32
感谢任何见解 - 这不是我的一周。
【问题讨论】:
-
回到它只是再次出现段错误。太奇怪了。
-
看一下python3的python包
notify2 -
好的,谢谢。更简单、线程友好且与窗口管理器无关