You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
FLPATH-4270 | [DCM] Policy description field has no max-length validation
FLPATH-4269 | [DCM] Policy priority field accepts non-integer values
FLPATH-4271 | [DCM] Policy priority field not marked as required
FLPATH-4244 | [DCM] Normalize policy enabled checks for defensive coding
FLPATH-4255 | [DCM] Policy priority uniqueness constraint not communicated
FLPATH-4250 | [DCM] Whitespace-only values pass form validation for required policy fields
Changes:
Fix policy form validation for Description and Priority fields, normalize enabled
checks, and reject whitespace-only required fields.
Add a 255-character max-length Yup rule to the Description field, with inline error
feedback matching the Display Name pattern (validation error on blur rather than
hard-blocking input at the DOM level).
Add .integer() and .required() Yup rules to the Priority field so decimal values
(e.g. 500.5) and an empty field are rejected with an explicit error message instead of
silently coercing to an integer or defaulting to 500.
Add step={1} to the Priority number input and block ./e/E characters via onKeyDown and onChange guards to prevent decimal strings from bypassing the Yup
integer check through JavaScript's Number() coercion.
Update the Priority label to "Priority *" to indicate it is a required field.
Update the Priority helper text to surface the API uniqueness constraint
(priority must be unique per policy type) so users are informed before hitting a 409.
Normalize the three inconsistent enabled checks in PoliciesTabContent to p.enabled ?? true so the Enabled column, Actions toggle, and edit form all agree
when enabled is undefined.
Add .trim() to the display_name and rego_code Yup rules so whitespace-only
values are rejected client-side instead of passing validation and being silently
rejected by the API after submit.
❌ Patch coverage is 37.50000% with 5 lines in your changes missing coverage. Please review.
✅ Project coverage is 53.99%. Comparing base (0239de6) to head (717ab05). ⚠️ Report is 7 commits behind head on main.
✅ All tests successful. No failed tests found.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Tickets:
Changes:
Fix policy form validation for Description and Priority fields, normalize enabled
checks, and reject whitespace-only required fields.
feedback matching the Display Name pattern (validation error on blur rather than
hard-blocking input at the DOM level).
.integer()and.required()Yup rules to the Priority field so decimal values(e.g. 500.5) and an empty field are rejected with an explicit error message instead of
silently coercing to an integer or defaulting to 500.
step={1}to the Priority number input and block./e/Echaracters viaonKeyDownandonChangeguards to prevent decimal strings from bypassing the Yupinteger check through JavaScript's
Number()coercion.(priority must be unique per policy type) so users are informed before hitting a 409.
enabledchecks inPoliciesTabContenttop.enabled ?? trueso the Enabled column, Actions toggle, and edit form all agreewhen
enabledis undefined..trim()to thedisplay_nameandrego_codeYup rules so whitespace-onlyvalues are rejected client-side instead of passing validation and being silently
rejected by the API after submit.