Skip to content

Conversation

ChrisPenner
Copy link
Member

@ChrisPenner ChrisPenner commented Mar 6, 2024

See #4753 ;

This rewrites the in-haskell LCA detector to pure SQLite.

Not sure how well tested this function is right now, and don't have time to work on this since it's just something I noticed while fixing bugs, so I'll just leave this here in case someone has time to look at it 🤞🏼

@ChrisPenner ChrisPenner changed the base branch from trunk to cp/speed-up-before-check March 6, 2024 19:55
Copy link
Contributor

mergify bot commented Mar 6, 2024

⚠️ The sha of the head commit of this PR conflicts with #4753. Mergify cannot evaluate rules on this PR. ⚠️

Comment on lines +2762 to +2770
WITH x_ancestors(id) AS (
$selectAncestorsOfX
), y_ancestors(id) AS (
$selectAncestorsOfY
) SELECT id FROM (
SELECT id FROM x_ancestors
INTERSECT
SELECT id FROM y_ancestors
) LIMIT 1
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I haven't tested this, (maybe I need a table alias?)

Not sure there's any guarantee of correct row order coming out of an INTERSECT, so should probably find a way to do that or we might not get the LEAST common ancestor.

Base automatically changed from cp/speed-up-before-check to trunk March 8, 2024 18:17
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant