Skip to content

Conversation

@Jfresh18
Copy link
Contributor

@Jfresh18 Jfresh18 commented Dec 4, 2025

Changes

Fixed the backend error closing and resetting the task form. Passes through the status of the task into the task form frontend validation schema, then conditionally validates the fields based on the status. For example in progress tasks require assignees, but backlogged tasks do not require them, so the frontend validation had to account for status. Also validate word count for all tasks and finish date for in progress tasks. Also moved the catching of backend errors into the NERFormModal so it does not automatically reset and close the form when an error is caught.

Notes

Goes beyond saving a task without assigning because other fields also did not save the task if they were incorrectly filled out. For the length of a task's note, the backend requires strictly less than 250 words, which seemed like a weird case but the frontend handles that according to the backend error. The screenshots below are what occurs after hitting save and check all of the added validations.

Screenshots

In Progress
Screenshot 2025-12-03 at 7 00 29 PM
Backlog
Screenshot 2025-12-03 at 7 00 48 PM
Completed
Screenshot 2025-12-03 at 7 01 12 PM

Checklist

It can be helpful to check the Checks and Files changed tabs.
Please review the contributor guide and reach out to your Tech Lead if anything is unclear.
Please request reviewers and ping on slack only after you've gone through this whole checklist.

  • All commits are tagged with the ticket number
  • No linting errors / newline at end of file warnings
  • All code follows repository-configured prettier formatting
  • No merge conflicts
  • All checks passing
  • Screenshots of UI changes (see Screenshots section)
  • Remove any non-applicable sections of this template
  • Assign the PR to yourself
  • No yarn.lock changes (unless dependencies have changed)
  • Request reviewers & ping on Slack
  • PR is linked to the ticket (fill in the closes line below)

Closes #3667

@Jfresh18 Jfresh18 self-assigned this Dec 4, 2025
@Jfresh18 Jfresh18 linked an issue Dec 4, 2025 that may be closed by this pull request
Copy link
Contributor

@superhvarn superhvarn left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, but wait for Griffin's review since I think he knows more about this.

Copy link
Contributor

@gcooper407 gcooper407 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Everything looks great, you just have the test check failing. It seems to be toast-related, likely due to changing which components actually generate the toast messages. Should be a simple fix, all you should need to do is go into StageGateWorkPackageModal.test.tsx and wrap the modal in a ToastProvider.

Just fix that, re-ping us for a re-review, and you'll be all good to go!
(also nice job making use of that word counter helper!)

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

Successfully merging this pull request may close these issues.

[Maintenence] - Error handling for saving a task without assigning

4 participants