PG1204 opened a new issue, #5683: URL: https://github.com/apache/texera/issues/5683
### Task Summary ### Context `WorkflowEditorComponent.applyOperatorBorder(operatorID)` recomputes validation as its first step: ```typescript const validation = this.validationWorkflowService.validateOperator(operatorID); ``` When called from the validation-stream subscriber in handleOperatorValidation, this is redundant, the stream's emitted event already carries the Validation result that was just computed in updateValidationState. Originally flagged as an optional nit during the PR #5146 review. Attempted in PR #5626 but split out per reviewer request so that PR could stay scoped to test restructuring. ### Proposed change In frontend/src/app/workspace/component/workflow-editor/workflow-editor.component.ts: - Add an optional validation?: Validation parameter to applyOperatorBorder; use it when provided, fall back to validateOperator(operatorID) otherwise. - In handleOperatorValidation, pass value.validation from the stream into the helper. - Operator-add subscription stays unchanged (no Validation in hand -> falls through to the lazy fetch). ### Required test Add a focused test in workflow-editor.component.spec.ts that asserts validateOperator is not called when a Validation argument is passed in. ### Related Issue #5318 / PR #5626 (where this was attempted and split out) ### Task Type - [x] Refactor / Cleanup - [ ] DevOps / Deployment / CI - [ ] Testing / QA - [ ] Documentation - [ ] Performance - [ ] Other -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
