Enhance Rematch Logic and Slot Filtering in Planning Path
Deploy Development / deploy (push) Successful in 41s
Test Suite / pytest-backend (push) Successful in 45s
Test Suite / lint-backend (push) Successful in 0s
Test Suite / build-frontend (push) Successful in 13s
Test Suite / k6 /health Baseline (push) Successful in 33s
Test Suite / playwright-tests (push) Successful in 1m13s
Deploy Development / deploy (push) Successful in 41s
Test Suite / pytest-backend (push) Successful in 45s
Test Suite / lint-backend (push) Successful in 0s
Test Suite / build-frontend (push) Successful in 13s
Test Suite / k6 /health Baseline (push) Successful in 33s
Test Suite / playwright-tests (push) Successful in 1m13s
- Introduced `filter_rematch_slot_indices` to exclude preserved slots from rematching, improving the accuracy of slot assignments. - Added `_slot_priority_for_rematch` to prioritize existing slot assignments during rematching, enhancing the robustness of the rematch process. - Updated `_run_roadmap_rematch_loop` to utilize the new filtering and prioritization logic, ensuring better handling of rematch scenarios. - Enhanced tests in `test_planning_path_rematch.py` to validate the new filtering behavior and ensure correct exercise restoration when not rejected. - Bumped version to reflect the new features and improvements.
This commit is contained in:
1 parent
f3710ac0a1
commit
b8f65e04c5
4 files changed
+223
-6
No files matched your search
@@ -1024,9 +1024,22 @@ export function applyMatchStepsToSlots(draft, apiSteps) {
|
||||
if (!step) {
|
||||
return base
|
||||
}
|
||||
const mappedPrimary = mapStepToPrimary(step, slot)
|
||||
const apiUnfilled =
|
||||
step.exercise_id == null &&
|
||||
(step.slot_status === 'unfilled' ||
|
||||
step.roadmap_match_source === 'unfilled' ||
|
||||
mappedPrimary.kind === 'empty')
|
||||
if (
|
||||
apiUnfilled &&
|
||||
slot.primary?.kind === 'library' &&
|
||||
slot.primary.exerciseId != null
|
||||
) {
|
||||
return base
|
||||
}
|
||||
return {
|
||||
...base,
|
||||
primary: mapStepToPrimary(step, slot),
|
||||
primary: mappedPrimary,
|
||||
}
|
||||
})
|
||||
|
||||
|
||||
Reference in new issue
Block a user