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

Python debugger shows a wrong file when stopped at a breakpoint #6260

Open
odisseus opened this issue Mar 12, 2024 · 0 comments
Open

Python debugger shows a wrong file when stopped at a breakpoint #6260

odisseus opened this issue Mar 12, 2024 · 0 comments
Assignees
Labels
awaiting-maintainer Awaiting review from Bazel team on issues product: CLion CLion plugin product: IntelliJ IntelliJ plugin type: bug

Comments

@odisseus
Copy link
Contributor

odisseus commented Mar 12, 2024

Description of the bug:

No response

Which category does this issue belong to?

Intellij, CLion

What's the simplest, easiest way to reproduce this bug? Please provide a minimal example if possible.

  1. Clone a Python project that has tests, for example https://github.com/christianfds/article-simple-bazel
  2. Import it into IntelliJ with the following project view file:
directories:
  .

derive_targets_from_directories: true

targets:

additional_languages:
  python
  1. Open a file with tests, e. g. libs/complex_calculations/tests/test.py
  2. Follow the IntelliJ prompts to set up a Python venv and install the project requirements.
  3. Run any test case in the file to make sure that the project is set up correctly.
  4. Place a breakpoint inside the test case, and launch it with debugging.

Expected behaviour: The execution is suspended, and the line with the breakpoint is highlighted

Actual behaviour: A new file tab is opened, which is located somewhere in the Bazel execroot, e. g. /private/var/tmp/_bazel_foo/4cd9340ff2eef52aa6659fe37648ff08/execroot/simple-bazel/bazel-out/darwin-fastbuild/bin/libs/complex_calculations/test.runfiles/simple-bazel/libs/complex_calculations/tests/test.py. This is actually a symlink pointing to the original source file. The execution is suspended and the line that corresponds to the breakpoint is highlighted, but this happens in the wrong tab.

Which Intellij IDE are you using? Please provide the specific version.

Idea IC-233.14475.28, also reproducible in Clion

What programming languages and tools are you using? Please provide specific versions.

Python 3

What Bazel plugin version are you using?

Locally built, commit d246169

Have you found anything relevant by searching the web?

This problem seems to be related to #319, #3097, #3823, #4151.

Any other information, logs, or outputs that you want to share?

No response

@odisseus odisseus added awaiting-maintainer Awaiting review from Bazel team on issues type: bug labels Mar 12, 2024
@github-actions github-actions bot added product: CLion CLion plugin product: IntelliJ IntelliJ plugin labels Mar 12, 2024
@sgowroji sgowroji assigned mai93 and unassigned sgowroji and iancha1992 Mar 12, 2024
@mai93 mai93 assigned tpasternak and unassigned mai93 Mar 12, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
awaiting-maintainer Awaiting review from Bazel team on issues product: CLion CLion plugin product: IntelliJ IntelliJ plugin type: bug
Projects
None yet
Development

No branches or pull requests

5 participants