Repository navigation
feat(tools): add advanced queue, state, and resilience assertions to xmc validator - #868
Merged
janzak-dev merged 3 commits intoSep 14, 2026
Conversation
janzak-dev
changed the base branch from
feat/nightly-validation-basic
to
feat/nightly-validation-tooling
September 14, 2026 08:01
There was a problem hiding this comment.
Code Review
This pull request enhances the nightly workload verification script and its validation library to support polling work units until they reach a terminal state, verifying their target queues, and matching experiment titles. Feedback on these changes highlights a few critical issues: first, catching AssertionError during polling prevents failing fast on static metadata mismatches (like queue or worker name mismatches) and unnecessarily waits for the timeout; second, checking the truthiness of the state enum values causes 0 (STATE_UNSPECIFIED) to be treated as falsy, triggering redundant fallback gRPC calls or failing to return the correct state.
This was referenced Sep 14, 2026
janzak-dev
force-pushed
the
feat/nightly-validation-advanced
branch
3 times, most recently
from
September 14, 2026 08:33
33d1d64 to
7c5f6ec
Compare
janzak-dev
marked this pull request as ready for review
September 14, 2026 08:48
janzak-dev
requested review from
andrzejfudro
and removed request for
AntonTyb
September 14, 2026 08:49
andrzejfudro
previously approved these changes
Sep 14, 2026
…xmc validator Enhance `xmc_entities_validator.py` with comprehensive validation capabilities: - WorkUnit state lifecycle tracking, terminal failure fail-fast (`TerminalFailureError`), and queue constraint validation. - Transient network error retry loops and title regex pattern matching. - XMC UI origin URL resolution (`resolve_ui_base_url()`). - Updated `demo_workload_verify.py` CLI to enforce queue constraints, title pattern, and state completion polling. - Comprehensive unit tests covering state mapping, failure states, retry timeouts, and UI URL resolution. TAG=agy CONV=dbcea664-0b27-47b6-894c-5cd2431fec9f
…ata mismatch fail-fast
janzak-dev
force-pushed
the
feat/nightly-validation-advanced
branch
from
September 14, 2026 11:10
d4dfa3f to
9289736
Compare
…nd rpc fallback logging
janzak-dev
force-pushed
the
feat/nightly-validation-advanced
branch
from
September 14, 2026 11:12
9289736 to
9ca7ca6
Compare
andrzejfudro
approved these changes
Sep 14, 2026
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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Stack Navigation
feat/nightly-validation-basic/feat/nightly-validation-toolingmainfeat/nightly-validation-advancedfeat/nightly-validation-toolingfeat/nightly-test-suitefeat/nightly-validation-advancedSummary
Adds advanced queue constraint extraction, WorkUnit state assertions, completion polling with transient error resilience, and terminal failure fail-fast behavior to
xmc_entities_validator.pyanddemo_workload_verify.py.Motivation & Context
Layer 1B in the nightly workload validation stack builds upon the basic validator (Layer 1A / PR #862). It equips the test harness with real-world resilience: polling until WorkUnits reach terminal
COMPLETEDstate, asserting expected scheduling queue placement (cpu-queue), detecting execution failures fast viaTerminalFailureError, retrying transient gRPC connection errors, and resolving UI deep-links.Key Changes
STATE_NAMESenum mapping andstate_enum_to_name()helper.extract_queue_name()andextract_work_unit_state()resolving status from current execution or ESS query.validate_work_units()with exponential/linear retry polling loop, count threshold validation, andTerminalFailureErrorfail-fast.validate_experiment()to assertexpected_title_pattern.resolve_ui_base_url()supporting custom domains, Cloudtop environments, and fallback ports.demo_workload_verify.pywith queue assertions, title verification, and completion reporting.Assumptions
None — requirements were fully specified.
Screenshot of a local run
Verification & Testing
bazel test //tools/nightly_tests:all(Passed: 1/1 test targets passed)./.githooks/pre-commit(Passed all lint, buildifier, gofmt, addlicense, and ruff checks)./tools/analyze_diff_size.py --base-ref feat/nightly-validation-basic...(Prod: 275 lines, Total: 636 lines — within all thresholds)Related Issues / Bugs
N/A
TAG=agy
CONV=dbcea664-0b27-47b6-894c-5cd2431fec9f