Uh oh!
There was an error while loading.Please reload this page.
- Notifications
You must be signed in to change notification settings - Fork33.3k
Cleanup unnecessary curframe_locals usage#124369
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 ourterms of service andprivacy statement. We’ll occasionally send you account related emails.
Already on GitHub?Sign in to your account
Cleanup unnecessary curframe_locals usage#124369
Uh oh!
There was an error while loading.Please reload this page.
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others.Learn more.
The code simplification LGTM.
While I'm normally paranoid about treating any attribute without a leading underscore as implicitly public (regardless of documentation status), the fact we don't documentany public attributes onpdb instances (only methods) makes me more comfortable with it here.
Thanks! In general attributes of |
986a4e1 intopython:mainUh oh!
There was an error while loading.Please reload this page.
The regression was detected by ipython's own testsuite.This part of the IPython code is expected to break again with python 3.14,because the curframe_locals attribute was removed in the PR cpython#124369.However, there are plans to restore this attribute for backward compatibility inPR cpython#125951 before the CPython 3.14 release.Url:ipython/ipython#14598Url:ipython/ipython@c1e945bUrl:python/cpython#124369Url:python/cpython#125951Url:ipython/ipython#14620Closes:https://bugs.gentoo.org/946568Signed-off-by: Gabi Falk <gabifalk@gmx.com>
The regression was detected by ipython's own testsuite.This part of the IPython code is expected to break again with python 3.14,because the curframe_locals attribute was removed in the PR cpython#124369.However, there are plans to restore this attribute for backward compatibility inPR cpython#125951 before the CPython 3.14 release.Url:ipython/ipython#14598Url:ipython/ipython@c1e945bUrl:python/cpython#124369Url:python/cpython#125951Url:ipython/ipython#14620Closes:https://bugs.gentoo.org/946568Signed-off-by: Gabi Falk <gabifalk@gmx.com>
The regression was detected by ipython's own testsuite.This part of the IPython code is expected to break again with python 3.14,because the curframe_locals attribute was removed in the PR cpython#124369.However, there are plans to restore this attribute for backward compatibility inPR cpython#125951 before the CPython 3.14 release.Url:ipython/ipython#14598Url:ipython/ipython@c1e945bUrl:python/cpython#124369Url:python/cpython#125951Url:ipython/ipython#14620Closes:https://bugs.gentoo.org/946568Signed-off-by: Gabi Falk <gabifalk@gmx.com>Closes:#39746Signed-off-by: Sam James <sam@gentoo.org>
This is just a cleanup for the workaround solution for frame locals. Before PEP 667, accessing
frame.f_localswill clear the changes pdb made toframe.f_localsso we had to copy it to a new dict and work on that. However, it still has its caveats like#102864.Now
f_localshas a clear meaning and behavior, we should try to use it as much as possible. This change has no user observable behavior change. Theoretically it's a little bit different than before because each call toframe.f_localscreates a new proxy, but in practice we should see no difference.@ncoghlan could you take a look at the PR? You are familiar with the concept of PEP 667 so I think your review would be helpful. Also it's the sprint and I don't want to throw everything on Irit :)