Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remove tsk_bug_assertion in pair_coalescence_rates triggered by fp error #3038

Merged
merged 1 commit into from
Oct 21, 2024

Conversation

nspope
Copy link
Contributor

@nspope nspope commented Oct 17, 2024

Apologies for dropping a bug fix immediately after a release (fixes #3035).

This removes an assertion from the C library that can be spuriously triggered by a floating point comparison against 1 (which should only happen in the edge case where a single time window contains all the coalescence events).

Copy link

codecov bot commented Oct 17, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 87.07%. Comparing base (84ebb0b) to head (39593ec).
Report is 2 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #3038      +/-   ##
==========================================
- Coverage   89.85%   87.07%   -2.78%     
==========================================
  Files          29       11      -18     
  Lines       32128    24666    -7462     
  Branches     5763     4556    -1207     
==========================================
- Hits        28868    21478    -7390     
+ Misses       1859     1824      -35     
+ Partials     1401     1364      -37     
Flag Coverage Δ
c-tests 86.69% <ø> (ø)
lwt-tests 80.78% <ø> (ø)
python-c-tests 89.05% <ø> (ø)
python-tests ?

Flags with carried forward coverage won't be shown. Click here to find out more.

Files with missing lines Coverage Δ
c/tskit/trees.c 90.68% <ø> (ø)

... and 18 files with indirect coverage changes

@jeromekelleher
Copy link
Member

Can we get a test case provoking the old assert?

@nspope
Copy link
Contributor Author

nspope commented Oct 17, 2024

I added a test that would hit the assert on main. There's a check for the failure condition (roundoff error) on the python side.

Copy link
Member

@jeromekelleher jeromekelleher left a comment

Choose a reason for hiding this comment

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

Nice - I think it's important to capture odd corner cases in the test suite as they tend to recur...

@nspope
Copy link
Contributor Author

nspope commented Oct 18, 2024

I agree! I think this is ready to go in, then?

@jeromekelleher jeromekelleher added the AUTOMERGE-REQUESTED Ask Mergify to merge this PR label Oct 18, 2024
@nspope
Copy link
Contributor Author

nspope commented Oct 18, 2024

Looks like mergify is failing with

Unable to update: user nspope is unknown.

Please make sure nspope has logged in Mergify dashboard.

I've logged out/in to mergify again but not sure if it'll pick up on that

@benjeffery
Copy link
Member

@Mergifyio rebase

Copy link
Contributor

mergify bot commented Oct 21, 2024

rebase

✅ Branch has been successfully rebased

@benjeffery benjeffery merged commit 16de381 into tskit-dev:main Oct 21, 2024
18 of 19 checks passed
@mergify mergify bot removed the AUTOMERGE-REQUESTED Ask Mergify to merge this PR label Oct 21, 2024
@benjeffery
Copy link
Member

Looks like mergify is failing with

Unable to update: user nspope is unknown.

Please make sure nspope has logged in Mergify dashboard.

I've logged out/in to mergify again but not sure if it'll pick up on that

I'm not sure why but recently it hasn't been merging PRs from accounts not on a fixed list. I've manual merged.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
3 participants