Handle missing form data in rollout phase and screenshot delete requests

Open
#18,082 0 comments 0 reactions 0 assignees View on GitHub

Maintainers usually reply within 1 day

Nobody has claimed this yet.

Assessment

Difficulty
2/5
Estimated time
1-3 hours
Newbie friendliness
58/100
Issue type
Bug
Clarity
Mostly clear
Activity status
Active
Tech stack
django, python
Domain
backend

Research direction

Start by locating the rollout phase and screenshot delete request handlers, then trace how each reads its form data, especially rollout_phases-TOTAL_FORMS and branch-feature-value-TOTAL_FORMS. Reproduce a delete request with the expected data missing and find the existing tests for these flows. Done means both cases avoid a 500 response; the issue does not specify the desired response.

Written by the indexing model from the issue text.

Description

Sentry reported MultiValueDictKeyError errors when deleting rollout phases and screenshots because the requests were missing the expected form data (rollout_phases-TOTAL_FORMS and branch-feature-value-TOTAL_FORMS). This could be caused by a user clicking a stale delete button or double-clicking while the form is being updated. Currently, these requests result in a 500 error. We should handle missing form data better to avoid these errors.

┆Issue is synchronized with this Jira Task

Dominant language
Python
Stars
152
Forks
231
Avg merge
23h 54m
Merged PRs (30d)
201

Getting set up

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from mozilla/experimenter

All issues in mozilla/experimenter

Similar issues

More Python issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.