Skip to content
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 our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Feature Request] Error/warning when function name is duplicated in code #557

Open
j-steve opened this issue Dec 12, 2023 · 0 comments
Open

Comments

@j-steve
Copy link

j-steve commented Dec 12, 2023

One of the most frequent + annoying issues I've had when developing in PyScript is that sometimes I'll accidentally duplicate the name of a function in code, often from copying a function to make a second slightly different version. When this occurs, there's no errors in the code, but one of the functions will never trigger regardless of its trigger decorators.

I thought perhaps this was just a "me" problem but I saw another user mentioned this issue.

TLDR; it would be great if PyScript was able to throw an error/warning if it detected repeated top-level function names in a Python file.

(I'm not sure how feasible this would be or whether it is beyond the scope of the PyScript project, feel free to close this FR if so.)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant