[Answered ]-Pydev console: checking variable values seems to be causing code to execute unexpectedly

2👍

When you hit a breakpoint and PyDev fills the variables view (where you can see the value of each variable), it’ll do a dir() on all the variables in the scope and a getattr() for each of those variables found (that’s a bit of a simplification on what the debugger does, but it’s close to it)…

So, it can’t really guess if some variable would have some side-effect or not… You can try closing the variables view to check if it’ll only do that if the variables are actually requested (although it could be that it requests some things even if it’s closed, not sure about that).

Leave a comment