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

F523: Regression: index out-of-bounds panic on invalid parameter indices #4863

Closed
Tracked by #4972
addisoncrump opened this issue Jun 5, 2023 · 2 comments · Fixed by #4872
Closed
Tracked by #4972

F523: Regression: index out-of-bounds panic on invalid parameter indices #4863

addisoncrump opened this issue Jun 5, 2023 · 2 comments · Fixed by #4872
Assignees
Labels
bug Something isn't working

Comments

@addisoncrump
Copy link
Contributor

Potentially, a .format'd string specifies a parameter outside of the number of real parameters:

"{8}".format(0, 1)

If a) the index specified in the template exceeds the number of parameters and b) there are unused format args, the F523 fix will panic (regression from: #4837)

This was detected by #4822.

@charliermarsh charliermarsh self-assigned this Jun 5, 2023
@charliermarsh charliermarsh added the bug Something isn't working label Jun 5, 2023
@addisoncrump addisoncrump changed the title F523: Regression: index out-of-bounds panic on invalid indices F523: Regression: index out-of-bounds panic on invalid parameter indices Jun 5, 2023
@charliermarsh
Copy link
Member

Will fix this today.

@charliermarsh
Copy link
Member

I had to modify the snippet a bit to reproduce: "{1} {8}".format(0, 1)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants