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

Test variable view for python REPL #24162

Open
1 of 3 tasks
amunger opened this issue Sep 23, 2024 · 1 comment
Open
1 of 3 tasks

Test variable view for python REPL #24162

amunger opened this issue Sep 23, 2024 · 1 comment
Assignees
Labels
testplan-item Test plan item/assignments for upcoming release

Comments

@amunger
Copy link

amunger commented Sep 23, 2024

Refs: #24066

Complexity: 2

Create Issue


Pre-requisites:

You must have python installed on your machine

Test steps

  1. ensure settings
"python.REPL.sendToNativeREPL": true
"notebook.experimental.variablesView": true,

and "jupyter.interactiveWindow.textEditor.executeSelection": false if jupyter is installed (default)

  1. open a python file and execute some code with shift enter (python.execInREPL) to create some variables. This should open the native REPL to the side.

e.g.

class A:
    prop1 = 1
    prop2 = 2

    def __init__(self, a, b):
        self.a = a
        self.b = b
        self.list = [1, 2, 3]

class B:
    propList = [A(100, 200), A(300, 400)]


aString = "Hello"
aList = [1, 2, aString]
aList.append(aList) # Circular reference
aTuple = (3, 4, aString)
aSet = {5, 6, aTuple, aString}
aDict = {7: 8, 9: aSet}
anInt = 10
aFloat = 11.2
anObject = A(12, 13)
nestedObject = B()

bigLongList = []
longList = []
string = 'ab' * 1000
for i in range(100000):
    bigLongList.append('string' + str(i) + string)
    longList.append(i)
  1. open the debug pane and explore the created variables in the "REPL variables" view
  2. also try executing code through the input box
@amunger amunger added feature-request Request for new features or functionality testplan-item Test plan item/assignments for upcoming release and removed feature-request Request for new features or functionality labels Sep 23, 2024
@ulugbekna
Copy link

oh, i love how the repl looks! This has progressed so much! I remember when we were working on a send-to-REPL for the ocaml extension a couple of years ago, we looked at how python ext does it, and it just used to just send the repl command to terminal and just wait a couple of sec hoping it gets launched by then :D

Now the experience is very sleek

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
testplan-item Test plan item/assignments for upcoming release
Projects
None yet
Development

No branches or pull requests

4 participants