Repository navigation
Report native fast-forward merge outcomes accurately - #7
Open
superlzyguy wants to merge 1 commit into
Open
superlzyguy wants to merge 1 commit into
superlzyguy wants to merge 1 commit into
Conversation
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.
doltMerge()currently returnsfast_forward: 0even when HEAD advances to exactly the incoming commit. Capture the native merge result and report1when it equals the resolved merge input. Resolve the source once and merge that immutable hash, so concurrent branch movement cannot change classification; preserve the caller's branch label in the merge commit message.Adds six tests: true fast-forward, three-way merge, already-up-to-date, fast-forward to a merge commit, quoted branch label, and missing source without a HEAD change.
Provenance:
ad3964c77fd49e153616cec9fd7271060f490e583ee46feec69996483df67964.node scripts/native-followup-probe.mjs, official 0.50.9, Linux x64, Node 24.21.0, rechecked October 19:headEqualsIncoming=true, enginefastForward=false. Diagnostic exits 1 as intended (it also reproduces an independent native reset defect).This upstream submission does not change the consumer's official 0.50.9 dependency or publish a fork package.
Fresh Linux x64 validation on upstream base
3c1824d5bf24f1b6c2e681d366fc02a395665809using the official 0.51.0 release amalgamation, Node 24.21.0 and Bun 1.4.2:npm install --ignore-scripts --package-lock=false,node scripts/download.js,node scripts/build-amalgamation.js,node-gyp rebuildsucceeded.bun test test/: 135 pass, 0 fail (6 files, 228 assertions). The checkout contains no prebuilt addon, so tests loadbuild/Release/doltlite.node.node-gyp buildand reran the same tests: 133 pass, exactly two failures (the two true fast-forward cases). Restored the patch afterward.