Skip to content

Search backend: fix key equality for type CommitMatch

Warren Gifford requested to merge cc/equal-keys into main

Created by: camdencheek

In a recent change, I added AuthorDate to the Key type so that we could sort commit matches by date. However, the pointer type is not traversed when comparing structs with struct equality, so equivalent commits from two different sources were not being evaluated as the same commit. This broke deduplication for and/or queries.

Test plan

I added a test for this specific regression, and plan to expand these tests as part of my continued work search backend health.

Merge request reports

Loading