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

Cannot run lines in multiple interactive windows at the same time #8615

Closed
xiejx5 opened this issue Dec 23, 2021 · 7 comments · Fixed by #8642
Closed

Cannot run lines in multiple interactive windows at the same time #8615

xiejx5 opened this issue Dec 23, 2021 · 7 comments · Fixed by #8642
Assignees
Labels
bug Issue identified by VS Code Team member as probable bug interactive-window Impacts interactive window verified Verification succeeded
Milestone

Comments

@xiejx5
Copy link

xiejx5 commented Dec 23, 2021

Environment data

  • VS Code version: 1.63.2
  • Jupyter Extension version: 2021.11.1001550889
  • Python Extension version: 2021.12.1559732655
  • OS and version: Windows 10 2004
  • Python and/or Anaconda version: 3.9
  • Type of virtual environment used: N/A
  • Jupyter server running: Local

Expected behaviour

Run two time-consuming codes in multiple interactive windows simultaneously, like in the 2021.10 version Jupyter.

Actual behaviour

The first window successfully executes the code, while the second window does not execute until the first window finishes.

Steps to reproduce:

Open an interactive window, and use "Run Selection/Line in Interactive Window" to send the following code.

while True:
   pass

image

Open a second interactive window, and use "Run Selection/Line in Interactive Window" to send the same code to the second window. The second window cannot execute the code unless we turn off the first window.
image

@xiejx5 xiejx5 added the bug Issue identified by VS Code Team member as probable bug label Dec 23, 2021
@xiejx5
Copy link
Author

xiejx5 commented Dec 23, 2021

I think the bug is related to the change of 2021.11.100.

"For interactive window commands (run all, run above, run below) add them to a queue instead of just trying to execute one by one. (#6982)"

Maybe different interactive windows should have their own queues?

@DonJayamanne
Copy link
Contributor

Thanks for filing this issue, we'll look into this in the new year.

@xiejx5
Copy link
Author

xiejx5 commented Dec 23, 2021

Merry Christmas and Thanks for your efforts in 2021.

@greazer
Copy link
Member

greazer commented Jan 3, 2022

Seems likely a dupe of #8022. Verify after that one is fixed.

@greazer greazer added this to the January 2022 milestone Jan 3, 2022
@greazer greazer added interactive-window Impacts interactive window and removed needs-triage labels Jan 3, 2022
@DonJayamanne DonJayamanne added the verified Verification succeeded label Jan 27, 2022
@JackyWeng526
Copy link

JackyWeng526 commented Jun 23, 2022

I have the same problem currently.
I want to test two python scripts simultaneously, but all outputs are messed up in ONE interactive window rather than executed in TWO interactive windows respectively.
Is there any suggestion to fix/recover my vscode settings for this issue?

@rchiodo
Copy link
Contributor

rchiodo commented Jun 23, 2022

I have the same problem currently. I want to test two python scripts simultaneously, but all outputs are messed up in ONE interactive window rather than executed in TWO interactive windows respectively. Is there any suggestion to fix/recover my vscode settings for this issue?

There's actually a setting for that:

image

If you set it to 'perFile' we'll create a new interactive window for every script you run from.

@JackyWeng526
Copy link

Thank you so much. It saves my coding life.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Jun 25, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
bug Issue identified by VS Code Team member as probable bug interactive-window Impacts interactive window verified Verification succeeded
Projects
None yet
Development

Successfully merging a pull request may close this issue.

6 participants