frequent xcb errors and hangs

Issue #584 closed
Mark created an issue

I'm getting frequent hangups where an unresponsive, undrawn (ie black) warning dialog box appears and I have to kill/restart. The only thing I consistently find is in valentina's log, where the last line is always:

#!c++

[2016.11.04 00:00:38:WARNING:(0)] : default: QXcbConnection: XCB error: 3 (BadWindow), sequence: 3788, resource id: 12583252, major code: 40 (TranslateCoords), minor code: 0
I'm using v0.5.0.1645a/1ce6931... but have had this problem for a while now. I'm running Arch Linux x86_64, can't find anything in the logs, and have repeatedly tried to reinstall both Valentina and now my complete qt5 installation. The only similar issue I could find is this one:

#527: Error: Pasting a wrong formula : every dialog box is "glued" to the screen and can't close file or Valentina.

I can frequently reproduce this behavior by just starting Valentina, opening File|Preferences, then pressing OK. As I was filling out this form, that didn't work, but when I tried to open a .val file, it hung. Below is a capture. The tail of the log file is:

#!c++

[2016.11.04 00:31:56:DEBUG:mainwindow.cpp(1942)] void MainWindow::ArrowTool(): v.mainwindow: Arrow tool.
[2016.11.04 00:31:56:DEBUG:mainwindow.cpp(1778)] void MainWindow::CancelTool(): v.mainwindow: Canceling tool.
[2016.11.04 00:31:56:DEBUG:mainwindow.cpp(1780)] void MainWindow::CancelTool(): v.mainwindow: Dialog closed.
[2016.11.04 00:31:56:DEBUG:mainwindow.cpp(1982)] void MainWindow::ArrowTool(): v.mainwindow: Enabled arrow tool.
[2016.11.04 00:31:56:DEBUG:mainwindow.cpp(2139)] void MainWindow::ActionDetails(bool): v.mainwindow: Show details scene
[2016.11.04 00:31:56:DEBUG:mainwindow.cpp(2057)] void MainWindow::ActionDraw(bool): v.mainwindow: Show draw scene
[2016.11.04 00:31:56:DEBUG:mainwindow.cpp(1942)] void MainWindow::ArrowTool(): v.mainwindow: Arrow tool.
[2016.11.04 00:31:56:DEBUG:mainwindow.cpp(1778)] void MainWindow::CancelTool(): v.mainwindow: Canceling tool.
[2016.11.04 00:31:56:DEBUG:mainwindow.cpp(1780)] void MainWindow::CancelTool(): v.mainwindow: Dialog closed.
[2016.11.04 00:31:56:DEBUG:mainwindow.cpp(1982)] void MainWindow::ArrowTool(): v.mainwindow: Enabled arrow tool.
[2016.11.04 00:31:56:DEBUG:mainwindow.cpp(1942)] void MainWindow::ArrowTool(): v.mainwindow: Arrow tool.
[2016.11.04 00:31:56:DEBUG:mainwindow.cpp(1778)] void MainWindow::CancelTool(): v.mainwindow: Canceling tool.
[2016.11.04 00:31:56:DEBUG:mainwindow.cpp(1780)] void MainWindow::CancelTool(): v.mainwindow: Dialog closed.
[2016.11.04 00:31:56:DEBUG:mainwindow.cpp(1982)] void MainWindow::ArrowTool(): v.mainwindow: Enabled arrow tool.
[2016.11.04 00:31:56:DEBUG:mainwindow.cpp(2139)] void MainWindow::ActionDetails(bool): v.mainwindow: Show details scene
[2016.11.04 00:31:56:DEBUG:mainwindow.cpp(2057)] void MainWindow::ActionDraw(bool): v.mainwindow: Show draw scene
[2016.11.04 00:31:56:DEBUG:mainwindow.cpp(1942)] void MainWindow::ArrowTool(): v.mainwindow: Arrow tool.
[2016.11.04 00:31:56:DEBUG:mainwindow.cpp(1778)] void MainWindow::CancelTool(): v.mainwindow: Canceling tool.
[2016.11.04 00:31:56:DEBUG:mainwindow.cpp(1780)] void MainWindow::CancelTool(): v.mainwindow: Dialog closed.
[2016.11.04 00:31:56:DEBUG:mainwindow.cpp(1982)] void MainWindow::ArrowTool(): v.mainwindow: Enabled arrow tool.
[2016.11.04 00:31:56:DEBUG:mainwindow.cpp(2057)] void MainWindow::ActionDraw(bool): v.mainwindow: Show draw scene
[2016.11.04 00:31:56:DEBUG:mainwindow.cpp(1942)] void MainWindow::ArrowTool(): v.mainwindow: Arrow tool.
[2016.11.04 00:31:56:DEBUG:mainwindow.cpp(1778)] void MainWindow::CancelTool(): v.mainwindow: Canceling tool.
[2016.11.04 00:31:56:DEBUG:mainwindow.cpp(1780)] void MainWindow::CancelTool(): v.mainwindow: Dialog closed.
[2016.11.04 00:31:56:DEBUG:mainwindow.cpp(1982)] void MainWindow::ArrowTool(): v.mainwindow: Enabled arrow tool.
[2016.11.04 00:31:56:WARNING:(0)] : default: QXcbConnection: XCB error: 3 (BadWindow), sequence: 1796, resource id: 12583531, major code: 40 (TranslateCoords), minor code: 0

Any insight/suggestions would really be appreciated - I'd really like to be able to use this again - thanks! Untitled.png

Comments (12)

  1. Roman Telezhynskyi repo owner

    @3sideslive, which version Qt do you use? Do you use KDE?

    QXcbConnection: XCB error: 3 (BadWindow), sequence

    As to this error i don't know what cause it. Google doesn't say much. I never meet it on my Ubuntu. Probably it related to some bug in Qt or KDE.

  2. Roman Telezhynskyi repo owner

    Any insight/suggestions would really be appreciated - I'd really like to be able to use this again - thanks!

    I have only one idea. We can try disable key Qt::AA_UseHighDpiPixmaps.

  3. Roman Telezhynskyi repo owner

    Okay, i did changes. We will enable the attribute only since Qt 5.6.0. Please, check.

  4. Mark reporter

    Thanks a lot. To answer your questions, I'm using QT v5.7.0. I'm not using KDE's desktop but do have several of their apps installed. I just use I3 as my window manager. This evening I will try the latest build as well as another WM and see what happens. Appreciate the help.

  5. Roman Telezhynskyi repo owner

    This mean my changes will not help you. I still don't know what is wrong in your case.

  6. Mark reporter

    Yes, I didn't read your note re Qt 5.6.0 closely enough. I've yet to figure out precisely where the issue stems from but found tonight that if I rename my ~/.config/ directory to hide it, the problem disappears. Running Valentina from a terminal, if I start to create a new pattern, then press cancel, I see the same XCB BadWindow error appear in the output, but the error is handled and everything continues as it should. If I get ambitious and am able to track it down I'll post here but assume that you are correct in the problem being with Qt. Thanks for the help.

  7. Roman Telezhynskyi repo owner

    We could hide warning messages that contain string "QXcbConnection: XCB error". What do you think?

  8. Mark reporter

    I think I've narrowed the problem down to the window manager I3. I can use other WM's without an issue. Even creating a new user and starting X with I3's default configuration causes this same problem with Valentina on my system. Because of this I've submitted an issue: Xcb Badwindow errors and hanging dialog box #2540 Let's see what they think :-)

  9. Mark reporter

    Just to wrap up, I can't get Valentina to startup in xtrace as per the WM dev's advice. I've closed that issue and think this can be closed for now as well since nobody else is experiencing this. Maybe it's something specific to my setup here. Regardless, since I have a workable solution for the present (using another WM), I'll keep doing that. On the other hand, this has made me curious and ticked off now. If something should shed some light on this in the future I'll add an update here. Thanks again.

  10. Roman Telezhynskyi repo owner

    @3sideslive, okay. Sorry about the problem. If only i could understand what is wrong. But as they said i know nothing about X.

  11. Log in to comment