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

Support vscode and intellij debuggers #303

Open
nyurik opened this issue Feb 4, 2025 · 1 comment
Open

Support vscode and intellij debuggers #303

nyurik opened this issue Feb 4, 2025 · 1 comment

Comments

@nyurik
Copy link

nyurik commented Feb 4, 2025

I have been trying to attach VSCode debugger to Clippy uitests, as I think Rust internal code is probably the most complex in the Rust ecosystem, and could really benefit from a step-by-step debugger with variable visualization. Internally, Clippy uses ui-test as an alternative harness. I documented in the CodeLLDB repo, but it seems there might need to be more communication between the maintainers to make it easier to debug.

I have also tried to use IntelliJ's Rust to debug Clippy, and if I manually supply LD_LIBRARY_PATH to the custom rustc toolchain, it fails because IntelliJ automatically adds --format=json -Z unstable-options --show-output - and fails because format does not understand json value. I wonder if ui_test should have the same CLI args as the default harness, or if there should be a well documented way for IDEs to attach to a non-default-harness tests? Thx!

/home/nyurik/dev/rust/lang/rust-clippy/target/debug/deps/compile_test-005862df71ed05a6 --format=json -Z unstable-options --show-output
@oli-obk
Copy link
Owner

oli-obk commented Feb 4, 2025

wonder if ui_test should have the same CLI args as the default harness,

Yes it should!

Anything else I can do to improve the "test failed, rerun with more flags/in gdb/logging" is a good thing, so I wanna do more than that, but it's a good minimal bar to meet

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants