← Back to Pull requests

fix(RHINENG-25441): ignore stale workspace name validation #3816

Closed
unknown closed this pull request without merging on Nov 21, 2026 15:48 UTC
View on GitHub
unknown unknown commented on Nov 12, 2026 20:03 UTC
Author

Jira


RHINENG-25441

What


Ignore stale workspace-name validation results when the user has already changed the input.

Why


An asynchronous duplicate-name check can finish after the user edits the field and leave a validation error for an older value on the current value.

How


Wrap the debounced create-workspace validator so only the most recent input can update field validation. Add a regression test for an older duplicate-name rejection arriving after a newer value was checked.

Testing


npm run test:local -- --runInBand src/components/InventoryGroups/Modals/CreateGroupModal.test.js — 9 tests passed.

npx eslint src/components/InventoryGroups/Modals/CreateGroupModal.js src/components/InventoryGroups/Modals/CreateGroupModal.test.js — no errors; one existing exhaustive-deps warning in CreateGroupModal.js.

git diff --check — passed.

UI verification was not performed; browser validation remains a manual check.

[RHINENG-25441]: https://redhat.atlassian.net/browse/RHINENG-25441?atlOrigin=eyJpIjoiNWRkNTljNzYxNjVmNDY3MDlhMDU5Y2ZhYzA5YTRkZjUiLCJwIjoiZ2l0aHViLWNvbS1KU1cifQ

Summary by Sourcery

Prevent outdated workspace-name validation responses from overriding the result for the latest edited value.

Bug Fixes:

  • Prevent stale asynchronous workspace-name validation results from applying errors to newer input values.

  • Ensure workspace-name validation runs while the field is being edited and rechecks values when they are entered again.
  • Enhancements:

  • Consolidate workspace-name validation and stale-result handling for create and rename workspace modals.

  • Add shared field behavior for displaying asynchronous validation feedback before blur.
  • Tests:

  • Add regression coverage for overlapping validation requests, stale successes and failures, repeated values, and pre-blur duplicate-name errors.
  • Fix recording:

    https://github.com/user-attachments/assets/2d5cb8f0-2826-4010-86dc-361f1e1b2c75

    Diff: 249 lines (+186 / -63) across 3 files Reviewer: h-kataria Review duration: 12704m
    All Vouch review confidence checks passed
    Residual risk 0.15 = Change Risk (0.39) × (1 − Review Confidence (0.60)). Review depth and reviewer attention state are adequate.
    Model 1 · Change Risk (XGBoost)
    Score: 0.39 · 249 lines diff across 3 files
    0.39
    Model 2 · Review Depth (DistilBERT)
    Depth Score: 0.17 · 1 substantive comment(s)
    0.17
    Model 3 · Review Timing & Attention
    Session adequacy: 100% · Reviewer familiarity: 35%
    60%
    Bedrock Claude 3 · Risk Narration
    (disconnected)
    Groq
    Groq Risk Narration
    AWS Bedrock is currently disconnected. Generate high-confidence PR triage narration on-demand using Groq.
    Model 1 · Change Risk Attribution
    SHAP Weights
    Diff Size diff_size
    0.330
    Shallow Review Depth shallow_review_depth
    0.289
    Real PR Conversation Timeline
    1 comments
    "Review active on #3816"
    general weight: 0.35
    Reviewers
    Assignees
    Unassigned
    Labels
    risk: low confidence: 60.5% reviewed
    Vouch Risk Breakdown
    AI-powered review risk analysis
    Change Risk
    Change Risk · Model 1 (XGBoost)
    Predicted defect probability (0.00–1.00) based on diff churn, modified sensitive files, and author risk history.
    Score: 39.0% (MEDIUM) · Higher = larger blast radius
    39.0%
    Review Confidence
    Review Confidence · Models 2 & 3
    Scrutiny score (0.00–1.00) combining DistilBERT semantic review depth with reviewer familiarity and session dwell time.
    Score: 60.5% · Lower = rushed or shallow review
    60.5%
    Residual Risk
    Residual Risk · Core Equation
    Residual = Change × (1 − Confidence)
    Unmitigated risk surviving review. ≥ 0.65 triggers an automated re-queue to protect production.
    Score: 15.4% · Safe to merge
    15.4%