Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

WxPython/GTK3 graphical glitches starting with debugpy 1.8.8 #1788

Open
etisserant opened this issue Dec 19, 2024 · 6 comments
Open

WxPython/GTK3 graphical glitches starting with debugpy 1.8.8 #1788

etisserant opened this issue Dec 19, 2024 · 6 comments
Assignees
Labels
needs repro Issue has not been reproduced yet

Comments

@etisserant
Copy link

etisserant commented Dec 19, 2024

Environment data

  • debugpy version: 1.8.8 and greater
  • OS and version: ubuntu 24.04
  • Python version 3.12.3
  • Tested with WxPython version 4.2.1 and 4.2.2

Actual behavior

WxWidget GUI isn't drawn properly when debugger is connected. Some widgets are not drawn at all, and damages are not systematically repaired when scaling window. Window top becomes kind of transparent and shows non-updated pixels from background that follow when dragging window.

Expected behavior

When connecting debugger, WxPython draws normally.

expected actual
Image Image
Image Image

Steps to reproduce:

  • install wxPython and debugpy with PIP
  • download WxPython demo
  • run it with python -m "debugpy" --listen localhost:5678 demo.py
  • attach with vscode
          {
              "name": "Attach",
              "type": "python",
              "request": "attach",
              "connect": {
                  "port": 5678,
              }
          }
    
    
    

With pypi's debugpy==1.8.7 problem doesn't occur.

@github-actions github-actions bot added the needs repro Issue has not been reproduced yet label Dec 19, 2024
@rchiodo
Copy link
Contributor

rchiodo commented Dec 19, 2024

Is there a reason you need to attach? It works fine for me launching it. In Linux attach uses GDB under the covers, that might be interfering with the thread that does the drawing.

@rchiodo
Copy link
Contributor

rchiodo commented Dec 19, 2024

It also doesn't have any problems on Windows which makes me think it's gdb related as well.

@etisserant
Copy link
Author

It happens also if I launch directly from vscode python debug extension, with or without "guiEventLoop": "wx" in launch.json specs.

The reason why I listen and connect on port 5678 is that invoking python manually with -m debugpy was faster to bisect debugpy versions with pip. Dunno why this is named "attach" in launch.json, there is no gdb PID attaching involved in my case.

It works if I downgrade ms-python.debugpy to Version 2024.12.0

@rchiodo
Copy link
Contributor

rchiodo commented Dec 19, 2024

Oh yeah you're right, it's not actually an attach. Not sure how 1.8.8 could have broken something so specific. It was us removing checked in binaries (only used in attach) and some minor bug fixes.

v1.8.7...v1.8.8

@AdamYoblick
Copy link
Member

@rchiodo The only thing I can think of regarding the pydevd binaries that we now build (instead of ingesting) from the pydevd repo is the environment in which they are built.

The image in the container we use to build the manylinux wheels has very old components, by design, for backcompat.

When I was refactoring the build, I got errors when building the manylinux wheels because the pydevd binaries we built outside of this container used dependencies that were much newer than those in the container.

So the solution was to move the compilation of the pydevd binaries to the same container used by the wheel generation. This made the build happy.

It's certainly possible that this caused unintended side effects when these binaries are used by Debugpy in a Linux environment. Our tests didn't see any failures through, but this might be an edge case?

@rchiodo
Copy link
Contributor

rchiodo commented Dec 19, 2024

That's what I initially thought - it was the new binaries we made. But this isn't an attach scenario, so those binaries aren't used.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
needs repro Issue has not been reproduced yet
Projects
None yet
Development

No branches or pull requests

3 participants