[issue46565] Delete module-level loop variables when no longer needed

2022-02-03 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: New changeset 0cbdd2131195b0d313762968f604e80a3e65ca9f by Nikita Sobolev in branch 'main': bpo-46565: `del` loop vars that are leaking into module namespaces (GH-30993) https://github.com/python/cpython/commit/0cbdd2131195b0d313762968f604e80a3e65ca9f

[issue46565] Delete module-level loop variables when no longer needed

2022-01-29 Thread Alex Waygood
Alex Waygood added the comment: I agree that the typeshed issue is less important than the output of dir() and help(). I also agree that we shouldn't make a fetish of typing. However, I see the typeshed issue less as an issue specific to typing, and more as an example that illustrates a

[issue46565] Delete module-level loop variables when no longer needed

2022-01-29 Thread Nikita Sobolev
Nikita Sobolev added the comment: Thanks for the better wording, Terry! > Leaving loop variables available is an intended feature of python. Just to be clear: it sure is! But, sometimes we don't want to polute a global namespace with this variable. A common practice across CPython's source

[issue46565] Delete module-level loop variables when no longer needed

2022-01-28 Thread Terry J. Reedy
Terry J. Reedy added the comment: I am opposed at this time. Leaving loop variables available is an intended feature of python. After reading point 1, I was tempted to say that you are making a fetish of typing or making the tail wag the dog. I mention this because others might have