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

KeyError: 'count' on prize acceptance form #820

Open
uraniumanchor opened this issue Mar 21, 2025 · 0 comments
Open

KeyError: 'count' on prize acceptance form #820

uraniumanchor opened this issue Mar 21, 2025 · 0 comments

Comments

@uraniumanchor
Copy link
Collaborator

uraniumanchor commented Mar 21, 2025

Describe the bug
Seeing this in the error reports. This line in particular, the count key is not present:

        else:
            if self.cleaned_data['count'] == 0:
                raise forms.ValidationError(
                    'You chose accept with 0 prizes. Perhaps you meant to click the other button? If you do not want any of your prizes, simply click the deny button.'
                )

To Reproduce
Steps to reproduce the behavior:

  1. Not sure yet. Can't tell from the automated reports if this is the form itself being broken, or not dealing with broken requests robustly.

Expected behavior

Form should display an error if there's an actual error, rather than triggering a 500.

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