T-208: Fix random_topology_tree ignoring constraints#219
Closed
ms609 wants to merge 1 commit intocpp-searchfrom
Closed
T-208: Fix random_topology_tree ignoring constraints#219ms609 wants to merge 1 commit intocpp-searchfrom
ms609 wants to merge 1 commit intocpp-searchfrom
Conversation
…e (T-208) When adaptiveStart=TRUE and constraints are active, the bandit could select RANDOM_TREE, which calls random_topology_tree() without constraint data. The resulting starting tree may violate constraints, causing TBR to block all constraint-relevant moves (cn=-1). Fix: fall back to random_wagner_tree(tree, ds, cd) when RANDOM_TREE is selected and cd->active is true. This preserves the random-start exploration intent while respecting topological constraints. Test: added adaptiveStart + constraint test (8 replicates).
ms609
added a commit
that referenced
this pull request
Mar 24, 2026
Owner
Author
|
Superceded by |
ms609
added a commit
that referenced
this pull request
Mar 25, 2026
Verifies all output trees satisfy constraints when adaptiveStart=TRUE forces RANDOM_TREE strategy with active constraints. Tests the random_constrained_tree() polytomy-resolution path on cpp-search. PR #219 is now superseded (its code fix replaced by random_constrained_tree on cpp-search); this preserves its test.
ms609
added a commit
that referenced
this pull request
Mar 25, 2026
- Close T-208 (cherry-picked to cpp-search, PR #219 closed) - Close T-211 (conservative-only impact, not worth fixing) - Add T-213 (impose_constraint, PARKED) and T-214 (multi-split bug) - Update T-212 status (tests committed, new GHA after heredoc fix) - Remove stray EOF heredoc artifacts from completed-tasks.md - Add S-PR to standing tasks
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.
Agent G.
Bug: When
adaptiveStart=TRUE(thorough preset) and constraints active, the bandit could selectRANDOM_TREE, which callsrandom_topology_tree()withoutConstraintData. The resulting starting tree may violate constraints, causing TBR to block all constraint-relevant moves (cn=-1). Could return constraint-violating trees.Fix: Fall back to
random_wagner_tree(tree, ds, cd)whenRANDOM_TREEis selected andcd->activeis true. Preserves random-start exploration intent while respecting constraints.Test: Added
adaptiveStart + constrainttest (8 replicates, 4 target hits).GHA: Run 23506900264 — PASS (Ubuntu ARM64 + Windows).