Page MenuHomePhabricator

Merge `diffusion.commitbranchesquery` into `diffusion.branchquery`
ClosedPublic

Authored by epriestley on Jan 17 2014, 11:17 PM.
Tags
None
Referenced Files
Unknown Object (File)
Tue, Nov 19, 9:20 PM
Unknown Object (File)
Sun, Nov 17, 3:38 PM
Unknown Object (File)
Fri, Nov 15, 4:50 PM
Unknown Object (File)
Tue, Nov 12, 8:20 AM
Unknown Object (File)
Fri, Nov 8, 7:06 AM
Unknown Object (File)
Wed, Nov 6, 12:37 AM
Unknown Object (File)
Wed, Nov 6, 12:37 AM
Unknown Object (File)
Wed, Nov 6, 12:37 AM
Subscribers

Details

Summary

Ref T4327. This is general cleanup since I was in this area of the code. Primarily, the Mercurial implementation here was completely broken and wrong:

  • It returned only one branch, but a commit can be present on many branches.
  • It did not account for multiple branch heads.
  • It returned a result implying the branch head pointed at the queried commit, which is no consistent or accurate.

Simplify the amount of API we're dealing with by collapsing this method into the very similar diffusion.branchquery method.

Test Plan

Looked at mercurial and git repositories and commits, branch information seemed correct.

Diff Detail

Branch
cparser5
Lint
Lint Passed
Unit
No Test Coverage

Event Timeline

epriestley updated this revision to Unknown Object (????).Jan 17 2014, 11:17 PM
  • Since 0 is a valid commit in Mercurial, use strlen() to test for $contains.