fix(merge): accept batch-existing.json in incremental updates#410
Open
s870488-dev wants to merge 1 commit into
Open
fix(merge): accept batch-existing.json in incremental updates#410s870488-dev wants to merge 1 commit into
s870488-dev wants to merge 1 commit into
Conversation
- Replace regex-based batch filtering with glob + explicit sort key - batch-existing.json now loads FIRST as base graph (sort key -1) - Numbered batches and multi-part batches sort numerically - Unrecognized patterns load last (defensive), not dropped - Fixes Lum1104#402: incremental updates silently lose all unchanged nodes Tested: synthetic end-to-end test with batch-existing (50 nodes) + batch-1 (3 updates) + batch-2-part-1/2 (2 new) + batch-fused-8-13 (1 new) → Output 53 nodes (was 3 before fix due to dropping batch-existing)
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.
Summary
Fixes #402 — incremental updates silently lose all unchanged nodes because
merge-batch-graphs.pydropsbatch-existing.json(regex only matches numeric batch indices).Root Cause
Lines 1036, 1089-1093: regex
batch-(\d+)(?:-part-(\d+))?\.jsonexcludesbatch-existing.json, causing it to be added tounrecognized_batch_filesand skipped during load.Fix
batch_sort_key()batch-existing.jsonsorts FIRST (key=-1) as base graphVerification
Ran end-to-end test with synthetic batches:
Checklist