You are right in that it shouldn't happen as per the rules of the scope (variables defined within function scope should be destroyed once they leave that scope) but still, it happens! You can call it a bug of the cpython interpreter though the chances of falling in this trap is very less. You'll have to be careless enough to accept a default parameter and not handle its value at all in the function and just let it free (which is quite rare).
For further actions, you may consider blocking this person and/or reporting abuse
We're a place where coders share, stay up-to-date and grow their careers.
You are right in that it shouldn't happen as per the rules of the scope (variables defined within function scope should be destroyed once they leave that scope) but still, it happens! You can call it a bug of the cpython interpreter though the chances of falling in this trap is very less. You'll have to be careless enough to accept a default parameter and not handle its value at all in the function and just let it free (which is quite rare).