I have a pdb
trace set inside a GET
request. I want to print all the attributes of the request object. I am trying the following, in pdb:
(Pdb) request
<GET /foo HTTP/1.1>
(Pdb) for d in dir(request):
*** SyntaxError: unexpected EOF while parsing (<stdin>, line 1)
I am sure there is something fundamental I am missing here.
At the pdb prompt, do the following:
(Pdb) a = [1, 2, 3, 4]
(Pdb) for i in a:
*** SyntaxError: unexpected EOF while parsing (<stdin>, line 1)
(Pdb) import code
(Pdb) code.interact(local=locals())
>>> for i in a:
... print i
...
1
2
3
4
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With